0

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
  • 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 01:49
  • Yes, the DNS records resolve to the same IP address. –  Mar 27 '10 at 02:55

1 Answers1

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.

Clint Miller
  • 1,141
  • 1
  • 11
  • 19