Passing system properties to Jetty Maven runner

0
5230
Jetty Maven Runner

When using maven jetty runner plugin, you might want to pass some system properties for the apps like this:


$ mvn jetty:run -Dproperty=value

It can be done via following config in pom.xml


<plugin>
       <groupId>org.mortbay.jetty</groupId>
       <artifactId>maven-jetty-plugin</artifactId>
       <version>6.1.10</version>
       <configuration>
            <systemProperties>
                <systemProperty>
                <name>propertyName</name>
                <value>${property}</value>
            </systemProperty>
        </systemProperties>
        </configuration>
</plugin>