Sunday, 8 January 2012

Tomcat: change the default ROOT "/" web application

I have copied foo.war into webapps. I want to access it when I request the URL http://localhost:8080/ (not I can access it on http://localhost:8080/foo/) Edit /etc/tomcat6/server.xml
<Host ...>
   <Context path="" docBase="foo" debug="0" reloadable="true">

How it should be..not working!

OK..I don't like this invasive way of editing server.xml. There is another way that didn't work for me (why?anybody?)

Edit /etc/tomcat6/Catalina/localhost/ROOT.xml:
<Context path="/"                                                                                                                                                              
         antiResourceLocking="false" />


No comments:

Post a Comment