views:

21

answers:

1

I have Apache running and serving PHP but I will also like to run JBOSS for my other web app. JBOSS is running on port 8080 while Apache is running on port 80. If there is a request for URL example.com, I want Apache to handle it because it is PHP backend but for URL example2.com, I want Apache to forward the request to port 8080 to be handled by JBOSS AS.

I appreciate any help in configuring Apache in the way I described it.

A: 

You need to use Apache proxy module: http://httpd.apache.org/docs/1.3/mod/mod_proxy.html

Your configuration of proxy will look similar to:

 ProxyRequests Off

 ProxyPass /foo http://foo.example.com:8080/foo
kogut