Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

If multiple sites are hosted within a single server, how can someone able to use Apache for PHP and JBoss for Seam.

Example:  example.com  -> servered using PHP
          example2.com -> servered using JBoss
share|improve this question
    
This will depend on whether the DNS records for those domains resolve to the same IP address (and would need to be served with name-based virtual hosting) or if they are set to resolve to separate IP addresses. Give us this information, and we can give you a good answer for how to accomplish this. –  Clint Miller Mar 27 '10 at 1:49
    
Yes, the DNS records resolve to the same IP address. –  Cory Mar 27 '10 at 2:55

1 Answer 1

Well, if you have to use the same IP address, you will need name-based virtual hosting in combination with a reverse proxy. For instance, you could use Apache in front of JBoss and set one name virtual host to example.com:80 and configure it as you normally would with mod_php.

For example2.com:80, configure a 2nd Apache name virtual host, but use mod_proxy to set Apache up to proxy requests to JBoss configured and listening on some other port (like 8080). This isn't too hard to get working. This article, plus the Apache documentation, of course, will be helpful.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.