Hey guys. I have FC5 installed on a computer with the DNS name... we'll call it green.domain.com. I'm running Apache 2 and Tomcat. I set an Alias to go to the Tomcat directory...
Alias /sxdm/ "/usr/local/tomcat/webapps/sxdm/"
If you go to http://green.domain.com/sxdm/
it shows the directory listing using Tomcat's webserver. That's okay for me. The application starts by going to http://green.domain.com/sxdm/servlet/portal
On the developer network DNS server, they added an entry for... orange.domain.com to the same IP address as green.domain.com. If I go to http://orange.domain.com/sxdm/servlet/portal
, it does the same thing as if I go to green. The Apache httpd.conf file has no mention of orange anywhere.
I was asked today to make it so if a user goes to http://orange.domain.com
it goes to http://orange.domain.com/sxdm/servlet/portal
. I thought about using VirtualHosts and making the document root /usr/local/tomcat/webapps/sxdm/servlet/portal but I think they want to see the URL http://orange.domain.com/sxdm/servlet/portal
My first response was to make an index.html file in the document root and use a meta refresh tag. And it works. But I have two problems with this: 1, it's client-side; and 2, if I go to http://green.domain.com
it will do the same redirect.
How to I make it so, on the server-side, a request for http://orange.domain.com
redirects to http://orange.domain.com/sxdm/servlet/portal
but green.domain.com is unaffected? Keep in mind I don't want to change the documentroot.