Cannot redeploy to remote tomcat 7 with using cargo-maven-plugin

rottmanj picture rottmanj · Jun 22, 2011 · Viewed 7.1k times · Source

I am attempting to build and redeploy to a remote tomcat 7 server using the cargo-maven plugin. I have been able to successfully deploy to the remote server, but all other actions fail.

Here is the pluging settings in my pom.xml

        <plugin>
            <groupId>org.codehaus.cargo</groupId>
            <artifactId>cargo-maven2-plugin</artifactId>
            <version>1.1.1</version>
            <configuration>
                <!-- Container configuration -->
                <container>
                    <containerId>tomcat7x</containerId>
                    <type>remote</type>
                </container>
                <configuration>
                    <type>runtime</type>
                    <properties>
                        <cargo.remote.username>tomcat</cargo.remote.username>
                        <cargo.remote.password>tomcat</cargo.remote.password>
                        <cargo.remote.uri>http://devserver:8080/manager/html</cargo.remote.uri>
                    </properties>
                </configuration>
            </configuration>                
        </plugin>

This is the error I am seeing within eclipse, when I attempt to deploy. I posted it to pastebin so it is easier to read. Error link. Any help with this is greatly appreciated.

Answer

rottmanj picture rottmanj · Jun 29, 2011

For anyone wanting to know the answer to this. Take a look at for a caveat with tomcat 7.

You can use something like this.

<plugin>
            <groupId>org.codehaus.cargo</groupId>
            <artifactId>cargo-maven2-plugin</artifactId>
            <version>1.1.1</version>
            <configuration>
                <container>
                    <containerId>tomcat7x</containerId>
                    <type>remote</type>
                </container>
                <configuration>
                    <type>runtime</type>
                    <properties>
                        <cargo.remote.username>devuser</cargo.remote.username>
                        <cargo.remote.password>86gphpphp</cargo.remote.password>
                        <cargo.remote.uri>http://192.168.2.116:8080/manager/text</cargo.remote.uri>
                    </properties>
                    <deployables>
                        <deployable>
                            <groupId>com.fiobox</groupId>
                            <artifactId>fiobox</artifactId>
                            <type>war</type>
                        </deployable>
                    </deployables>
                </configuration>
            </configuration>
        </plugin>