How to redirect OpenNMS via Apache and eventually use SSL

Hello, I need to redirect OpenNMS via Apache web server and eventually use SSL. do we have these process documents?

I hope there might be people in chat.opennms.com in the opennms-discussion channel who are willing to help build a similar knowledge base article to the NGINX one. We can use your wiki post here as a working space. What do you think?

<VirtualHost *:443>
ServerName opennms.example.com

ErrorLog logs/opennms_error_log
TransferLog logs/opennms_access_log
LogLevel debug

SSLEngine on

SSLProtocol             all -SSLv3 -TLSv1 -TLSv1.1
SSLCipherSuite          ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256
SSLHonorCipherOrder     on
SSLCompression          off
SSLSessionTickets       off

SSLCertificateFile /path/to/opennms.example.com/fullchain.pem
SSLCertificateChainFile /path/to/opennms.example.com/fullchain.pem
SSLCertificateKeyFile /path/to/opennms.example.com/privkey.pem

CustomLog logs/ssl_request_log \
          "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"

ProxyPreserveHost On
ProxyRequests On

ProxyPass /opennms http://127.0.0.1:8980/opennms
ProxyPassReverse /opennms http://127.0.0.1:8980/opennms

</VirtualHost>

Don’t want SSL? change virtualhost to *:80 and remove everything that starts with SSL plus the CustomLog

2 Likes

works for me

Thank you, also are there any configs on OpenNMS properties to be changed?