18.关于pom文件中Tomcat插件的设置

来源:互联网 发布:电子画板手绘软件 编辑:程序博客网 时间:2024/06/11 02:00
<build>  <plugins>  <!-- 配置Tomcat插件 ,用于启动项目 --><plugin><groupId>org.apache.tomcat.maven</groupId><artifactId>tomcat7-maven-plugin</artifactId><!--如果不设置,则默认为猫的自定义端口,项目路径为http://localhost:默认端口/项目名  --><configuration><!--如果端口号改为8081:那么访问的时候路径的端口就要写成8081,否则404  --><port>8080</port><!-- 如果设置为/,则项目了路径为http://localhost:端口号 /--><!-- 如果设置为/123,则项目了路径为http://localhost:端口号/123 --><path>/123</path></configuration></plugin>  </plugins>  </build>

原创粉丝点击