Starting cargo with maven

View: New views
2 Messages — Rating Filter:   Alert me  

Starting cargo with maven

by RichardS :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I would like to deploy a jetty web site running a WAR that is stored in my maven repository/

Based on the example projects, I tried the following

1) Added a normal dependency ( icecream.war.version} is defined elsewhere

               <dependency>
<groupId>com.metservice</groupId>
<artifactId>ICECream</artifactId>
<version>${icecream.war.version}</version>
<type>war</type>
</dependency>

2) Added the cargo plug

<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<configuration>
<wait>true</wait>
<container>
<containerId>jetty6x</containerId>
<log>
${project.build.directory}/${containerId}/cargo.log
</log>
<type>embedded</type>
</container>

<deployables>
<deployable>
<groupId>com.metservice</groupId>
<artifactId>ICECream</artifactId>
<type>war</type>
<properties>
<context>ICECream</context>
</properties>

</deployable>
</deployables>

</configuration>
</plugin>

3) ran the cargo:start target....


Jetty started on port 8080 but did not deploy my WAR - only a thing called cargocpc.war

I cant see anything obviously wrong????

Richard

Re: Starting cargo with maven

by RichardS :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

mmm, I missed the double level of configuration

Thats going to catch out a lot of idiots like me!



<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<configuration>
<configuration>

<deployables>
???
</deployables>
</configuration>
</configuration>
</plugin>

On Mon, Dec 15, 2008 at 8:27 AM, richard schmidt <hangstrap@...> wrote:
I would like to deploy a jetty web site running a WAR that is stored in my maven repository/

Based on the example projects, I tried the following

1) Added a normal dependency ( icecream.war.version} is defined elsewhere

               <dependency>
<groupId>com.metservice</groupId>
<artifactId>ICECream</artifactId>
<version>${icecream.war.version}</version>
<type>war</type>
</dependency>

2) Added the cargo plug

<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<configuration>
<wait>true</wait>
<container>
<containerId>jetty6x</containerId>
<log>
${project.build.directory}/${containerId}/cargo.log
</log>
<type>embedded</type>
</container>

<deployables>
<deployable>
<groupId>com.metservice</groupId>
<artifactId>ICECream</artifactId>
<type>war</type>
<properties>
<context>ICECream</context>
</properties>

</deployable>
</deployables>

</configuration>
</plugin>

3) ran the cargo:start target....


Jetty started on port 8080 but did not deploy my WAR - only a thing called cargocpc.war

I cant see anything obviously wrong????

Richard