In the development of the project software before the general need to remove the name of the project, before using the Tomcat online there are a lot of information can find themselves, but today the configuration of the jetty to write
I'm using Maven for management, and I just need to configure the following in Pom.xml
Detailed configuration:
<build>
<finalName>maven02</finalName>
<plugins>
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>9.2.8.v20150217</version>
<configuration>
<port>80</port>
<webAppConfig>
<contextPath>/contextPath>
</webAppConfig>
<webDefaultXml>src/main/resources/webdefault.xml</webDefaultXml>
<stopKey>shutdown</stopKey>
<stopPort>9966</stopPort>
</configuration>
</plugin>
</plugins>
</build>
Main configuration:
<webAppConfig>
<contextPath>/contextPath>
</webAppConfig>
That's it.
If it helps you, don't forget to praise it.