This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Tomcat and the fly likes different port to different app Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "different port to different app" Watch "different port to different app" New topic
Author

different port to different app

fatima silveira
Greenhorn

Joined: Oct 16, 2007
Posts: 1
Hi there,

i'm using tomcat 6 and i'm having a problem

i need to to 2 things...
i have to make my tomcat access a diferent .war file if i type the url with different port number...

eg: i have test.war and test1.war
if i type http://localhost:8180 i must start the app test (just like if i typed http://localhost:8080/test) and if i type http://localhost:8181 it must start the app test1 (like http://localhost:8080/test1)

i did it once using the tag service... but i didn't save it and tomcat overwrote my file, now i can't find the way i did it before... i tried several things like

<Service name="lt1">
<Host name="localhost" appBase="webapps"
unpackWARs="true" autoDeploy="true"
xmlValidation="false" xmlNamespaceAware="false">

<Connector port="8180" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443"
proxyPort="80"
disableUploadTimeout="true"/>

<Context path="/" docBase="lt1" debug="0" reloadable="true" >
</Sevice>

<Service name="lt2">
<Host name="localhost" appBase="webapps"
unpackWARs="true" autoDeploy="true"
xmlValidation="false" xmlNamespaceAware="false">

<Connector port="8181" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443"
proxyPort="80"
disableUploadTimeout="true"/>
<Context path="/" docBase="lt1" debug="0" reloadable="true" >
</Sevice>

but it dont work... and i dont want do use the tag server...

If someone know how can i do this will be a greate help!!

thanks
 
jQuery in Action, 2nd edition
 
subject: different port to different app
 
Similar Threads
virtual hosts in stand alone tomcat
How to configure two applications on different ports...?
Tomcat manager not opening
Different log files for different services in tomcat
Different log files for different services in tomcat