1 server.xml
<context path= "/smswap" reloadable= "true" docbase= "D:\workspace\smswap\WebRoot" ></Context> Let's look at AppBase first, this directory says: 1 subdirectories under this directory will automatically be deployed as apps. 2. War files under this directory will be automatically decompressed and deployed as an app and docbase just points to your app's directory, which can have nothing to do with appbase. Summarize: If you want to specify the path yourself, then you should be in Docbase. If you want to be simple, just copy them to AppBase. If you repeat them, 2 points to a directory and looks like it will work, but each subdirectory below your app is actually deployed as a separate application. For example, your application is MYAPP, put it in the D:\project\myApp There are 2 subdirectories inside. D:\project\myApp\images D:\project\myApp\js You can pass 1 setting AppBase point to D:\project for automatic system deployment 2 You can manually specify docbase to D:\PROJECT\MYAPP 3 If you specify AppBase to D:\PROJECT\MYAPP, then D:\project\myApp\images this will no longer be a normal subdirectory, but rather a separate virtual directory, or it is called an application. Because it is automatically deployed D:\project\myApp\js also the same consequences Http://www.blogjava.net/jjshcc/archive/2010/06/16/323659.html |
Tomcat Configuration Learning