Deploying a War File to Tomcat Root With Maven pom.xml

前端 未结 3 655
没有蜡笔的小新
没有蜡笔的小新 2021-01-15 15:03

Assuming the following pom.xml maven would build a client.war file which when deployed to Tomcat will have the URL www.server.com:8080/client

3条回答
  •  情歌与酒
    2021-01-15 15:21

    Since you're using the combination of eclipse, tomcat, and maven, I'm going to make the guess that the m2e-wtp plugin is in use here. There's a FAQ that addresses this. This also shows though how to change your context root in a maven specific way (using the war plugin for specifying a finalName for the war) which results in a correctly named war file (such as ROOT.war as mentioned in other answers.

提交回复
热议问题