tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wang Penghui <wangpeng...@gmail.com>
Subject appBase & docBase in <Host> element in server.xml
Date Thu, 14 Dec 2006 02:10:00 GMT
Hello, list,

I am a little mess up with the configuration of tomcat 5.5.20 now.

I use the follow configuration to setting up two Virtual Host in server.xml

<Host className="org.apache.catalina.core.StandardHost"
appBase="/home/test/wwwroot" autoDeploy="true"
configClass="org.apache.catalina.startup.ContextConfig"
contextClass="org.apache.catalina.core.StandardContext" debug="0"
deployXML="true"
errorReportValveClass="org.apache.catalina.valves.ErrorReportValve"
liveDeploy="true"
mapperClass="org.apache.catalina.core.StandardHostMapper"
name="test.jsp-test.bizcn.com" unpackWARs="true">
<Context path="" docBase="" reloadable="true" debug="0"/>
</Host>
<Host className="org.apache.catalina.core.StandardHost"
appBase="/home/test2/wwwroot" autoDeploy="true"
configClass="org.apache.catalina.startup.ContextConfig"
contextClass="org.apache.catalina.core.StandardContext" debug="0"
deployXML="true"
errorReportValveClass="org.apache.catalina.valves.ErrorReportValve"
liveDeploy="true"
mapperClass="org.apache.catalina.core.StandardHostMapper"
name="test2.jsp-test.bizcn.com" unpackWARs="true">
<Context path="" docBase="" reloadable="true" debug="0"/>
</Host>

And both of them work correctly.

I have digged some articles which related to the virtual host on tomcat
and found something unclear about the appbase and docbase.

Here are some examples, could you tell me which one is correct.

1. appbase = "/home/test/wwwroot" docbase = "".
and the default path of docbase should be appbase/ROOT
2. appbase = "/home/test/wwwroot" docbase = "/home/test/wwwroot/ROOT"
the same as the above configuration
3. appbase = "/home/test/wwwroot" docbase = "/home/test/wwwroot"
is it correct or workable? I have not tested it yet.
4. appbase = "webapps" docbase = "/home/test/wwwroot"
is it correct or workable?

Thanks very much.

Wang.



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message