最近在用jenkins部署项目,所以开启了tomcat下自带的manager这些app项目,server.xml里面deployonstartup属性配置为true,后来发现会引起quzart的定时任务会跑两遍,所以只好将deployonstartup属性改为了false,然后再在context下面加了几个虚拟目录。
最后配置如下
<Host name="localhost" appBase="webapps"
unpackWARs="true" autoDeploy="false" deployOnStartup="false">
<Context path="" docBase="project" debug="0" reloadable="false" crossContext="true"/>
<Context path="host-manager" docBase="host-manager" debug="0" reloadable="false"/>
<Context path="manager" docBase="manager" debug="0" reloadable="false"/>
<Context path="probe" docBase="probe" debug="0" reloadable="false"/>
<Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log." suffix=".txt"
pattern="%h %l %u %t "%r" %s %b" />
</Host>
访问xxxx:xx/manager会弹出输入框,但是进去后会报错
最终目的就是想不让定时任务跑两遍,然后我还能使用tomcat下的manager的功能,请问应该如何去做呢