How to deploy EAR remotely to JBoss 5.1.0.GA using the Cargo maven plugin?

Has anyone successfully uninstalled EAR remotely in 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> 

As a result, you receive the following error message:

 java.io.IOException: Server returned HTTP response code: 500 for URL: http://myserver:8888/jmx-console/HtmlAdaptor?action=invokeOpByName&name=jboss.system:service%3DMainDeployer&methodName=deploy&argType=java.net.URL&arg0=file:d%3A%5Cear%5Cmy-ear-1.0-SNAPSHOT.ear 
+3
source share
1 answer

As far as I know, remote deployment with JBoss does not work out of the box (the problem is that the file to be deployed must exist locally on the JBoss server). This issue is described in detail in CARGO-416 , which is still open (I don’t know if the patch can be applied smoothly).

Someone mentions a dirty workaround in this thread (in short, ftping to deploy to a remote machine first), but it does not seem very satisfactory.

Update: CARGO-416 is fixed in Cargo 1.0.3 and remote deployments on JBoss AS are now supported and documented in the special JBoss Remote Deployer wiki page.

+6
source

Source: https://habr.com/ru/post/1302690/


All Articles