0

I am trying to achieve this:

subdomain.mydomain.com/customerA -> internalserver1/application/ subdomain.mydomain.com/customerB -> internalserver2/application/

This broght me to the login page of the application (on mobile only and with no images):

ProxyPass /customerA http://internalserver1/application
ProxyPassReverse /customerA http://internalserver1/application
ProxyPass /customerB http://internalserver2/application
ProxyPassReverse /customerB http://internalserver2/application

Reading here made me add this:

ProxyPass /application http://internalserver1/application
ProxyPassReverse /application http://internalserver1/application

This made images available, but I don't see how to apply this to multiple servers.

I think I need to use mod_rewrite, but I don't get how. Also, I don't get why the above only works on mobile and not on desktop.

Thanks!

gvnn
  • 3

1 Answers1

1

mod_rewrite won't do you any good.

The best option would be to configure your backend servers to serve the HTML with the correct base URL (/customerA/ instead of /application/).

If this is not possible you can use ProxyHTMLURLMap from mod_proxy_html to rewrite the HTML before it is served.

This will however add latency to your requests and load to your proxy server.

Gerald Schneider
  • 26,582
  • 8
  • 65
  • 97