How to disable specific apps from starting during Tomcat startup?

前端 未结 4 1114
灰色年华
灰色年华 2021-01-04 10:54

My company is preparing a new production box while the current one is running. I would like to proactively install applications in Tomcat container of the new production box

相关标签:
4条回答
  • 2021-01-04 11:30

    In the <Host> element of your conf/server.xml put deployOnStartup="false". Reference: Tomcat Host documentation

    0 讨论(0)
  • 2021-01-04 11:38

    You can simply rename de WEB-INF directory inside the webapp that you don't want to auto-start to some other name like Disabled-WEB-INF, before starting tomcat.

    Later on, if you wish to start that app, while tomcat is running, simply rename back the directory to WEB-INF.

    0 讨论(0)
  • 2021-01-04 11:39

    You can use tomcat web application manager; this webapp does let you stop any application inside tomcat from running.

    0 讨论(0)
  • 2021-01-04 11:44

    add deployIgnore attribute in <Host>, and the value is the regular expression of the dirs you want to ignore, if you want to ignore foo,just set deployIgnore="foo" and you want to ignore more dirs,use regular expressions to set the values

    0 讨论(0)
提交回复
热议问题