apache2 tomcat6 virtual hosting

Posted by user3215 on Ask Ubuntu See other posts from Ask Ubuntu or by user3215
Published on 2010-12-10T07:39:04Z Indexed on 2011/01/15 12:59 UTC
Read the original article Hit count: 415

Filed under:
|
|
|

I've apache2 and tomcat6 running on port 80 on ubuntu server 9.10. I've a registered domain name and I'll access the jsp index page navigating to http://abc.mydomain.com. The page is under tomcat_home/webapps/myapp and the below are tomcat virtual hosting in server.xml file:

<Host name="abc.mydomain.com" debug="0" appBase="webapps" unpackWARs="true">
<Logger className="org.apache.catalina.logger.FileLogger"
directory="logs" prefix="virtual_log1." suffix=".log" timestamp="true"/>
<Context path="" docBase="/usr/share/tomcat/webapps/myapps" debug="0" reloadable="true"/>
</Host>

Recently a new domain has been bought(xyz.mydomain.com) and I'm asked to do the virtual hosting so that the new domain name directly points the page "admin.jsp" which is located under 'tomcat_home/webapps/myapps/WE-INF/js/'. How could I do this?

If I type http://abc.mydomain.com/admin I'll get the page what I wanted. I should access the page just by typing http://xyz.mydomain.com.

© Ask Ubuntu or respective owner

Related posts about ubuntu-server

Related posts about 9.10