Skip to content

Commit 4164a2f

Browse files
author
sarah
committed
Fixes errors for the mvn clean install tomcat7:run command
1 parent d1242a4 commit 4164a2f

File tree

1 file changed

+49
-19
lines changed

1 file changed

+49
-19
lines changed

pom.xml

Lines changed: 49 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,15 @@
1111
<packaging>war</packaging>
1212
<name>bookstore Maven Webapp</name>
1313
<url>http://maven.apache.org</url>
14+
1415
<properties>
1516
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
1617
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
1718
<maven.compiler.source>1.8</maven.compiler.source>
1819
<maven.compiler.target>1.8</maven.compiler.target>
1920
<failOnMissingWebXml>false</failOnMissingWebXml>
2021
</properties>
22+
2123
<dependencies>
2224
<dependency>
2325
<groupId>javax.servlet</groupId>
@@ -79,6 +81,7 @@
7981
<version>2.0.0-beta.5</version>
8082
</dependency>
8183
</dependencies>
84+
8285
<build>
8386
<finalName>bookstore</finalName>
8487
<plugins>
@@ -91,25 +94,6 @@
9194
<path>/</path>
9295
<contextReloadable>true</contextReloadable>
9396
</configuration>
94-
<executions>
95-
<execution>
96-
<id>start-tomcat</id>
97-
<phase>pre-integration-test</phase>
98-
<goals>
99-
<goal>run</goal>
100-
</goals>
101-
<configuration>
102-
<fork>true</fork>
103-
</configuration>
104-
</execution>
105-
<execution>
106-
<id>stop-tomcat</id>
107-
<phase>post-integration-test</phase>
108-
<goals>
109-
<goal>shutdown</goal>
110-
</goals>
111-
</execution>
112-
</executions>
11397
</plugin>
11498
<plugin>
11599
<groupId>de.qaware.maven</groupId>
@@ -128,6 +112,7 @@
128112
</plugin>
129113
</plugins>
130114
</build>
115+
131116
<profiles>
132117
<profile>
133118
<id>integration</id>
@@ -155,6 +140,51 @@
155140
</execution>
156141
</executions>
157142
</plugin>
143+
144+
<plugin>
145+
<groupId>org.apache.tomcat.maven</groupId>
146+
<artifactId>tomcat7-maven-plugin</artifactId>
147+
<version>2.2</version>
148+
<configuration>
149+
<port>8080</port>
150+
<path>/</path>
151+
<contextReloadable>true</contextReloadable>
152+
</configuration>
153+
<executions>
154+
<execution>
155+
<id>start-tomcat</id>
156+
<phase>pre-integration-test</phase>
157+
<goals>
158+
<goal>run</goal>
159+
</goals>
160+
<configuration>
161+
<fork>true</fork>
162+
</configuration>
163+
</execution>
164+
<execution>
165+
<id>stop-tomcat</id>
166+
<phase>post-integration-test</phase>
167+
<goals>
168+
<goal>shutdown</goal>
169+
</goals>
170+
</execution>
171+
</executions>
172+
</plugin>
173+
<plugin>
174+
<groupId>de.qaware.maven</groupId>
175+
<artifactId>go-offline-maven-plugin</artifactId>
176+
<version>1.1.0</version>
177+
<configuration>
178+
<dynamicDependencies>
179+
<DynamicDependency>
180+
<groupId>org.apache.maven.surefire</groupId>
181+
<artifactId>surefire-junit4</artifactId>
182+
<version>2.18.1</version>
183+
<repositoryType>PLUGIN</repositoryType>
184+
</DynamicDependency>
185+
</dynamicDependencies>
186+
</configuration>
187+
</plugin>
158188
</plugins>
159189
</build>
160190
</profile>

0 commit comments

Comments
 (0)