用eclipse向tomcat部署中tomcat设置(备忘)

来源:互联网 发布:淘宝保险平台 编辑:程序博客网 时间:2024/06/07 05:30

主要是权限和锁定问题

1、conf\tomcat-users.xml中的根节点下添加

<role rolename="manager-gui"/>
<user username="tomcat" password="tomcat" roles="manager-script,tomcat"/>

2、conf\context.xml下的根节点上添加 antiJARLocking="true" antiResourceLocking="true"

<Context antiJARLocking="true" antiResourceLocking="true">    <!-- Default set of monitored resources. If one of these changes, the    -->    <!-- web application will be reloaded.                                   -->    <WatchedResource>WEB-INF/web.xml</WatchedResource>    <WatchedResource>${catalina.base}/conf/web.xml</WatchedResource>    <!-- Uncomment this to disable session persistence across Tomcat restarts -->    <!--    <Manager pathname="" />    -->    <!-- Uncomment this to enable Comet connection tacking (provides events         on session expiration as well as webapp lifecycle) -->    <!--    <Valve className="org.apache.catalina.valves.CometConnectionManagerValve" />    --></Context>


3、部署路径

协议://ip:端口号/manager/text

如:http://192.168.1.100:8080/manager/text


0 0
原创粉丝点击