I would like to access the tomcat urls via Apache such that i can forward requests from Apache to forward requests as below
With this setup, I am able to access https://host.com but internal links https://host.com/app1/ref/link1/ on the webpage doesnot work
<VirtualHost *:443>
ServerName host.com
SSLEngine on
SSLCertificateFile /etc/httpd/ssl/server.crt
SSLCertificateKeyFile /etc/httpd/ssl/server.key
ProxyRequests Off
SSLProxyEngine on
# Proxy requests to the backend server (Tomcat)
ProxyPass / https://server.com/app1
ProxyPassReverse / https://server.com/app1
<Location />
Require all granted
Header edit Location ^https://server.com/app1(.*) https://host.com/$1
Header edit Set-Cookie "(.*)" "$1;HttpOnly;Secure;SameSite=None"
</Location>
ErrorLog logs/server_error_log
CustomLog logs/server_access_log combined
</VirtualHost>
New contributor
lasa is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.