tomcat 自动进入工程目录及动态发布关闭

tomcat/conf/server.xml

<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true">
<!-- 增加以下内容 -->
<Context path="/" docBase="appName" reloadable="false" />

path为用户访问本tomcat的根目录时, 相当于访问到docBase设置的工程目录内
reloadable为动态检测.class文件有变更时自动使用新的.class, 正式项目上线时候置为false. 为false时工程内容变更需重启tomcat

评论

h
hw_7864

⭐️ Admin快速开发: https://show.cool-admin.com/

赞 0
h
hw_7864

⭐️ 官方文档: https://cool-js.com

赞 0
h
hw_7864

⭐️ chatgpt在线体验: https://cool-js.com/ai/chat-vip/index.html?r=helloworld

赞 0