Skip to Content

Basic configuration for Jetty and tomcat maven plugins

Cheatsheet for jetty and tomcat maven plugins

This is a quick memento on how to set up tomcat7-maven-plugin and jetty-maven plugin (current version is 8).

It is interesting to note both of these servers are servlet 3.0 compatible.

Setting up Jetty :

Now your can run mvn jetty:run

To set up tomcat-7 plugin, you will have to add either the plugin to the pluginManagement section of your pom (more portable) - see below - or adding the pluginGroup to your settings.xml.

Now your can run mvn tomcat7:run

pluginGroup :

<pluginGroups>
    ....
    <pluginGroup>org.apache.tomcat.maven</pluginGroup>
    ....
</pluginGroups>
comments powered by Disqus