You are on page 1of 2

Maven Instructions:

In maven folder: in settings.xml add the server:

<!-- Configure the Tomcat Maven plugin user -->


<server>
<id>maven-tomcat-war-deployment-server</id>
<username>war-deployer</username>
<password>maven-tomcat-plugin</password>
</server>

In the project folder : in pom.xml add the plugin for tomcat

<!-- Configure the Tomcat Maven plugin -->


<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<server>maven-tomcat-war-deployment-server</server>
<url>http://localhost:8080/manager/text</url>
<path>/ishop</path>
</configuration>
</plugin>

In tomcat server: in tomcat-users.xml add the following user :

<!-- User to deploy WAR file to Tomcat from Maven -->


<user username="war-deployer" password="maven-tomcat-
plugin"
roles="manager-gui, manager-script, manager-jmx" />

To build and deploy the application:


mvn install tomcat7:deploy

mvn install tomcat7:redeploy

Test the application :

Login : alfred.sapine@ggmail.com
Password : password

You might also like