打开tomcat安装目录,根据路径找到 server.xml   路径D:\apache-tomcat-7.0.70\conf\server.xml  

打开后   找到这一段  

<Connector port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />

port="80" 在这里指定端口

 

然后找到这一段  

<Host name="www.egongyepin.com" appBase="webapps"
unpackWARs="true" autoDeploy="true">

指定域名name="www.egongyepin.com"

 

在Host中添加  <Context path="/" docBase="/leimingtech-front" debug="0" reloadable="true"></Context> 


如  <Host>

 <Context path="/" docBase="/leimingtech-front" debug="0" reloadable="true"></Context> 

</Host>

其中  docBase="/leimingtech-front"为我们指定的项目名称,也就是访问域名直接打开的项目,也可一指定页面什么的。

 

相关文章:

  • 2021-04-21
  • 2021-11-09
  • 2021-04-07
  • 2022-12-23
  • 2017-11-23
  • 2021-11-19
猜你喜欢
  • 2022-12-23
  • 2022-01-19
  • 2022-12-23
  • 2021-07-01
  • 2021-11-29
  • 2022-01-17
  • 2022-12-23
相关资源
相似解决方案