Skip to content

Instantly share code, notes, and snippets.

@bmatthews68
Last active June 25, 2020 20:40
Show Gist options
  • Select an option

  • Save bmatthews68/8205812 to your computer and use it in GitHub Desktop.

Select an option

Save bmatthews68/8205812 to your computer and use it in GitHub Desktop.
How to set system properties for the Jetty and Tomcat 7 Maven Plugins.
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<configuration>
<systemProperties>
<systemProperty>
<name>property.name</name>
<value>property.value</value>
</systemProperty>
</systemProperties>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<configuration>
<property.name>property.value</property.name>
</configuration>
</plugin>
@kmturley
Copy link
Copy Markdown

Tomcat example is incorrect. It should also be nested inside system properties like this:

<plugin>
  <groupId>org.apache.tomcat.maven</groupId>
  <artifactId>tomcat7-maven-plugin</artifactId>
  <configuration>
    <systemProperties>
      <property.name>property.value</property.name>
    </systemProperties>
  </configuration>
</plugin>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment