Put in the application of the external network, the user is directly input domain name access, I believe no one behind also add a tail, and Tomcat's default directory is root, so we need to change its default directory.
Changing the default directory for Tomcat is simple, just need to modify the Server.xml.
Specifically, with the content tag between <Host></Host>, you can understand that each content represents an app.
The specific properties of the content are:
<context path = "" debug= "0" docBase = "/OPT/APACHE-TOMCAT/WEBAPPS/WSBM" reloadable= "true" privileged= "true" >
</Context>
The key in this is the Docbase and path properties, and Docbase sets the directory accessed by path. The value of docBase can be either an absolute path or a relative path relative to the value of "AppBase" (AppBase is a property of the host tag), and the value of the Path property must be an empty string, and he sets the access path. An empty string means no path (that is, the default path for Tomcat), and if you set it to "/AAA", then your Access path will be preceded by the domain name "AAA"
Another thing to note: The Name property of the host tag, which is the hostname, of course, you can understand that the access name is the domain name or IP address, the default value is localhost, must be changed to your domain name or access to the IP address, or you use non-localhost access is useless.
For example, your name is localhost, and you enter http://www.xxx.com in the address bar is not accessible to your app's still Tomcat home page. You must set it to www.xxx.com to access your app.
Default access path for "Go" tomcat