Tomcat修改默认根目录
2024-08-23 12:13:51
tomcat7默认的程序发布路径为tomcat/webapps/ROOT/下面
修改Tomcat配置文件server.xml
<Host name="localhost" appBase="webapps"
unpackWARs="true" autoDeploy="true"> <!-- SingleSignOn valve, share authentication between web applications
Documentation at: /docs/config/valve.html -->
<!--
<Valve className="org.apache.catalina.authenticator.SingleSignOn" />
--> <!-- Access log processes all example.
Documentation at: /docs/config/valve.html
Note: The pattern used is equivalent to using pattern="common" -->
<Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log." suffix=".txt"
pattern="%h %l %u %t "%r" %s %b" /> </Host>
name为本地访问地址、appBase为项目的父地址,均可以修改。在host标签之间加入如下标签
<Context path="" docBase="example" debug="0" reloadable="true" />
此刻example目录和ROOT目录的作用是一样了
最新文章
- hadoop之输入输出格式
- neon汇编,C嵌入汇编
- bind,unbing,on,live,delegate绑定和解绑事件
- git服务器gitlab之搭建和使用--灰常好的git服务器【转】
- systemtap 列出所有linux 内核模块与相关函数0
- 一道阿里面试题(js)
- CodeForces 631B Print Check
- 11 Python+selenium对下拉框(select)进行处理
- jquery中this和event.target的区别
- IIS6/7 配置操作
- ES5与ES6中的继承
- python note 01 计算机基础与变量
- String,StringBuffer与StringBuilder的理解
- VirtualBox安装CentOS7
- JSP开发Web应用系统
- 【文文殿下】【CF724C】Ray Tracing (中国剩余定理)
- c++作业之圆面积
- 转:Launch Screen在iOS7/8中的实现
- windows下的IO模型之异步选择(WSAAsyncSelect)模型
- Ubuntu无法sudo提权,报当前用户不在sudoers文件中错误
热门文章
- react基础篇四
- [Advanced Algorithm] - Symmetric Difference
- swift里 as、as!、as?区别 T.Type与动态类型
- http 请求头示例
- uni-app的专属强大自适应单位upx,但是这个这是一个大坑,不能动态赋值解决办法
- Vue.js大总结
- WERTYU(WERTYU, UVa10082)
- [luogu1447 NOI2010] 能量采集 (容斥原理)
- [CodeForces]1059C Sequence Transformation
- CentOS7安装Kubernetes