I have tomcat running behind Apache for the last 2 years and everything is going well. I'm using AJP connector (mod_proxy) to do this. However I now wish to enable SSL and when I create the vhost section for SSL and try access my application over SSL the tomcat section of my application doesn't work. Can anyone tell me what/where I've gone wrong. Below is the Apache vhost, tomcat server.xml and version numbers for various things.
Apache vhost:
<VirtualHost REMOVED-IP:443>
ServerAdmin [email protected]
ServerName XXX.XXXXXXXXXXXXX.co.uk
DocumentRoot /var/www/websites/applicationsvr/live
ErrorLog /var/log/apache2/live_ssl_error.log
CustomLog /var/log/apache2/live_ssl_access.log common
SSLCertificateKeyFile /etc/apache2/ssl/XXXXXXXXXXXXX.co.uk.key
SSLCertificateFile /etc/apache2/ssl/XXXXXXXXXXXXX.co.uk.co.uk.crt
SSLCACertificateFile /etc/apache2/ssl/XXXXXXXXXXXXX.co.uk.intermediate.crt
SSLEngine on
SSLVerifyClient optional
SSLVerifyDepth 2
ProxyPass /app ajp://REMOVED-IP:8009/orbeon/
ProxyPassReverse /app ajp://REMOVED-IP:8009/orbeon/
</VirtualHost>
Tomcat server.xml
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" connectionTimeout="5000" keepAliveTimeout="5000"/>
Other:
OS: Ubuntu 12.04.2 x64
Kernel: 3.2.0-57
Apache: 2.2.22
Tomcat: 7.0.26
JVM Version: 1.6.0_27-b27
JVM Vendor: Sun Microsystems Inc.
One of my clients that uses the application had an issue accessing the tomcat section of the application using port 8080 (default) and while testing with them we found that the config that has worked (non-ssl) was the only way to get it going. Is it possible to enable SSL in this configuration?
TO enable proxy execution while using SSL you should add "SSLProxyEngine on" to your config.