JavaWeb_1.Tomcat 配置
1、输入域名,跳转到自己发布的界面
1.打开tomcat根目录/conf/server.xml
<Server>
<Service name="Catalina">
//连接端口设置80,为浏览器请求
<Connector port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443"/>
//引擎,默认域名为:shuiqing.art
<Engine name="Catalina" defaultHost="shuiqing.art">
//host配置
<Host name="shuiqing.art" appBase="\webapps\wind"
unpackWARs="true" autoDeploy="true">
//docBase:登录tomcat默认的主页所在的文件夹,这个量默认情况下指定的是ROOT文件夹
<Context path="" docBase="网站根路径" reloadable="true"/>
</Host>
</Engine>
</Service>
</Server>
2.找到tomcat根目录下的conf目录下的web.xml文件(在conf目录下),在最下面找到
<welcome-file-list>
//index.html位于自己项目下的页面
<welcome-file>index.html</welcome-file>
</welcome-file-list>
3.修改自己项目WEB-INF下web.xml的欢迎首页
<welcome-file-list>
<welcome-file>index.html</welcome-file>
</welcome-file-list>