tomcat7 - How to set the context path of a web application in Tomcat 7.0 -
I know that I can change the name of my webpad (or its wise file) root But this is a terrible way to do this, IMHO I now use the Tomcat Dock & amp; It says that elements directly to the server It is not advisable to put it in XML file So I have suggested it another way that he has suggested. So I have a But when I failed to load the reference on "/" even after deploying the server after restarting, it still has What you can do the following; This ROOT.xml will override the default settings for that engine and host (Catalina and localhost) for the original reference of the typic installation. Enter the following in the ROOT.xml file; here, And you can go there, your app is now the default application and it is , however, there is a side effect; Your application will be loaded twice. Once, once for and then it should be all right!
/META-INF/context.xml with the following code,
"/" & lt; WEB_APP_NAME & gt; ; "
In the ROOT.xml
& lt; Catalina_home & gt; Add a file named / conf / Catalina / localhost /
& lt; Contact dockbase = "& lt; yourApp & gt;" Path = "" reloadable = "true" />
& lt; YourApp & gt; is the name of, okay, your app .. :)
http: // localhost: 8080 < / Code>
localhost: 8080 and
localhost: 8080 / yourApp . To fix this, you can send your application to the outside
& lt; Catalina_home & gt; / Webapp and can use a relative or full path in the Dobbas tag of ROOT.xml. something like that;
& lt; Reference docbase = "/ opt / mywebapps /" yourapp & gt; " Path = "" reloadable = "true" />
Comments
Post a Comment