views:

1566

answers:

2

Has someone successfully deployed EAR remotely to JBoss 5.1.0.GA? My pom.xml configuration is as follows:

<plugin>
    <groupId>org.codehaus.cargo</groupId>
    <artifactId>cargo-maven2-plugin</artifactId>
    <version>1.0.1-SNAPSHOT</version>

    <configuration>
        <container>
            <containerId>jboss51x</containerId>
            <type>remote</type>
            <timeout>600000</timeout>
        </container>

        <configuration>
            <type>runtime</type>
            <properties>
                <cargo.remote.username>username</cargo.remote.username>
                <cargo.remote.password>password</cargo.remote.password>
                <cargo.hostname>myserver</cargo.hostname>
                <cargo.servlet.port>8888</cargo.servlet.port>
            </properties>
        </configuration>

        <deployer>
            <type>remote</type>
            <deployables>
                <deployable>
                </deployable>
            </deployables>
        </deployer>
    </configuration>
</plugin>

This results in the following error message:

java.io.IOException: Server returned HTTP response code: 500 for URL:
 http://myserver:8888/jmx-console/HtmlAdaptor?action=invokeOpByName&amp;name=jboss.system:service%3DMainDeployer&amp;methodName=deploy&amp;argType=java.net.URL&amp;arg0=file:d%3A%5Cear%5Cmy-ear-1.0-SNAPSHOT.ear
+5  A: 
Pascal Thivent
as I understand it, the problem isn't with Cargo itself, but with the JBoss deployer expecting the file to be local.
Ken Liu
@Ken Yes, indeed, this sounds more like a problem with JBoss deployer (how can it be called "remote" without handling the upload) but at the end, this doesn't work with/from Cargo.
Pascal Thivent
A: 

I've seen this plugin used before. It hasn't worked perfectly for me, though, so YMMV.

http://mojo.codehaus.org/jboss-maven-plugin/

cwash