Apache Web Server with Tomcat 7 - Mapping VirtualHost to Context (mod_jk)
posted 3 years ago
I have been reading for a time now and still couldn't figure out how to map a VirtualHosts defined in Apache Web Server to point to different Tomcat Contexts.
I am using Apache 2.2x and what I did so far is:
To httpd.conf file, I added :
And in the httpd-vhosts.conf file :
And I have the workers file :
Assuming that Tomcat has Context "DomainA" for www.a.com, and "DomainB" for www.b.com, I can reach these sites by simply typing www.a.com/DomainA/ and www.b.com/DomainB/
What I want is to access these sites without attaching Context names,"DomainA" or "DomainB" to actual domain names. More clearly I want to access these sites just by using the domain names.
Would please somebody direct me to the correct path ..