There are two options:
- pom.xml:
<plugin> <groupId>org.mortbay.jetty</groupId> <artifactId>maven-jetty-plugin</artifactId> <version>6.1.10</version> <configuration> ... </scanTargetPatterns> <systemProperties> <systemProperty> <name>jetty.port</name> <value>8080</value> </systemProperty> </systemProperties> </configuration> </plugin>
- command prompt: mvn -Djetty.port=8090 jetty:run
The thing to remember is the command line value will override the value in pom.xml.