我已经在OpenNMS 6.5上安装了CentOS (1.12.8),但是我很难让CentOS界面在SSL下运行。我可以使用默认端口设置8980启动OpenNMS,但是当我尝试修改/opt/opennms/etc/opennms.properties文件以侦听端口8443时,它根本无法工作。根据文档,它应该通过取消配置的一行注释来工作!
我可以看到端口8980通过netstat打开,但我从未看到8443。我甚至可以将8980更改为80,并且按预期工作,所以我认为opennms.properties文件是可以的。在这一点上,我假设在Jetty的配置和HTTPS方面还有更深层次的东西要错过。有什么想法吗?
发布于 2014-11-25 13:50:03
我试图使用OpenNMS中内置的Jetty启用SSL,但它也不起作用。现在,我正在使用apache在SSL下运行Opennms。
要做到这一点,您需要做的事情非常简单:
首先安装apache。
然后配置站点的.conf文件。我的看起来是这样的:
<IfModule mod_ssl.c>
ProxyRequests Off
# Rewrite http to https
RewriteEngine on
RewriteCond %{80} !^443$
RewriteRule ^/?(.*) https://%{HTTP_HOST}/$1 [NC,R=301,L]
<VirtualHost *:443>
# General setup for the virtual host
DocumentRoot "/opt/opennms/jetty-webapps/opennms"
<Directory "/opt/opennms/jetty-webapps/opennms">
Order allow,deny
Allow from all
</Directory>
SSLEngine on
SSLProtocol all -SSLv2
SSLCipherSuite HIGH:!ADH
# Set up ssl cerfiticates
SSLCertificateFile "/home/ubuntu/2b0a025bef6e41.crt"
SSLCertificateKeyFile "/home/ubuntu/keyFile.key"
SSLCertificateChainFile "/home/ubuntu/gd_bundle-g2-g1.crt"
CustomLog /var/log/apache2/ssl_request_log ssl_combined
</VirtualHost>
</IfModule>在配置文件中,您需要使用自己的DocumentRoot、Directory以及用于SSL cerfiticates的目录。
然后通过运行ssl模块和站点,
sudo a2enmod ssl
sudo a2ensite your-site.conf最后重新启动apache。
sudo service apache2 restarthttps://stackoverflow.com/questions/24169797
复制相似问题