Skip to content

Commit 482b043

Browse files
author
Fernando Lozano
committed
Add cargo plugin
1 parent e90e581 commit 482b043

File tree

2 files changed

+44
-11
lines changed

2 files changed

+44
-11
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@
77
$ git clone https://github.com/hdiv/insecure-bank.git
88
2. Run the application using an embedded Tomcat:
99

10-
$ mvn tomcat7:run-war
10+
$ mvn clean package
11+
$ mvn cargo:run
12+
1113
3. You can then access the bank application here: http://localhost:8080/insecure-bank/
1214

1315
## Login credentials

pom.xml

Lines changed: 41 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,47 @@
3232
<failOnMissingWebXml>false</failOnMissingWebXml>
3333
</configuration>
3434
</plugin>
35-
<plugin>
36-
<groupId>org.apache.tomcat.maven</groupId>
37-
<artifactId>tomcat7-maven-plugin</artifactId>
38-
<version>2.2</version>
39-
<configuration>
40-
<server>tomcat-development-server</server>
41-
<port>8080</port>
42-
<path>/${artifactId}</path>
43-
</configuration>
44-
</plugin>
35+
<plugin>
36+
<groupId>org.codehaus.cargo</groupId>
37+
<artifactId>cargo-maven2-plugin</artifactId>
38+
<version>1.3.3</version>
39+
<configuration>
40+
<container>
41+
<containerId>tomcat7x</containerId>
42+
<zipUrlInstaller>
43+
<url>https://archive.apache.org/dist/tomcat/tomcat-7/v7.0.85/bin/apache-tomcat-7.0.85.zip</url>
44+
</zipUrlInstaller>
45+
</container>
46+
<deployables>
47+
<deployable>
48+
<type>war</type>
49+
<properties>
50+
<context>/insecure-bank</context>
51+
</properties>
52+
</deployable>
53+
</deployables>
54+
</configuration>
55+
<executions>
56+
<execution>
57+
<id>default-cli</id>
58+
<goals>
59+
<goal>run</goal>
60+
</goals>
61+
<configuration>
62+
<configuration>
63+
<properties>
64+
<cargo.jvmargs>
65+
<!-- Hdiv JVM arguments -->
66+
</cargo.jvmargs>
67+
<cargo.servlet.port>8080</cargo.servlet.port>
68+
<cargo.tomcat.ajp.port>8009</cargo.tomcat.ajp.port>
69+
<cargo.rmi.port>8205</cargo.rmi.port>
70+
</properties>
71+
</configuration>
72+
</configuration>
73+
</execution>
74+
</executions>
75+
</plugin>
4576
</plugins>
4677
<finalName>insecure-bank</finalName>
4778
</build>

0 commit comments

Comments
 (0)