有两个上下文,一个docBase部署第一个,但不部署第二个

时间:2019-02-21 15:35:03

标签: tomcat tomcat7 web-deployment

我正在将两个Web应用程序部署到tomcat,这是server.xml的摘录

<Context allowLinking="true" path="" docBase="/home/mike/develop/shop/bin/platform/ext/littleshop/web/webroot" disableURLRewriting="true" useHttpOnly="true">
    <Manager pathname="" />
    <Loader platformHome="/home/mike/develop/shop/bin/platform" className="de.hybris.tomcat.HybrisWebappLoader" deployName="default" />
</Context>

<Context allowLinking="true" path="/app1" docBase="/home/mike/develop/shop/bin/platform/ext/hac/web/webroot" >
    <Manager pathname="" />
    <Loader platformHome="/home/mike/develop/shop/bin/platform" className="de.hybris.tomcat.HybrisWebappLoader" deployName="default" />
</Context>

<Context allowLinking="true" path="/app2" docBase="/home/mike/develop/shop/bin/platform/ext/hac/web/webroot" >
    <Manager pathname="" />
    <Loader platformHome="/home/mike/develop/shop/bin/platform" className="de.hybris.tomcat.HybrisWebappLoader" deployName="default" />
</Context>

如果我访问protocol:// host:port / app1,它可以工作,但是如果我尝试访问protocol:// host:port / app2,它将失去上下文,并将我发送到为protocol://部署的应用程序host:port(其docBase为/ home / mike / develop / shop / bin / platform / ext / littleshop / web / webroot的那个端口)

什么情况会导致这种情况? Tomcat部署app1,但不部署app2。

任何帮助将不胜感激!

0 个答案:

没有答案