更改8080端口访问
在conf文件夹下的server.xml文件中修改
找到 8080 端口位置,修改为80
<Connector port="80" protocol="HTTP/1.1"
更改默认根目录
在conf文件夹下的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" />
<Context path="" docBase="D:/tomcat/webapps/sacshop/" debug="0"/>
</Host>
同时在web.xml中检查
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
如果没有你需要的入口文件,自行照样设置。