We're updating the issue view to help you get more done. 

Cannot perform remote deployment if Tomcat is behind Apache mod_proxy

Description

See: https://groups.google.com/d/msgid/codehaus-cargo/69c1fa24-852f-418e-a234-b245fe1f1459%40googlegroups.com?utm_medium=email&utm_source=footer

Hi,
if I try to deploy a .war through port 80 (instead of the usual 8080) with maven plugin I get:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 [java] Caused by: org.codehaus.cargo.container. ContainerException: Failed to deploy [/mypath/mywebapp.war] [java] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.deploy(AbstractTomcatManagerDeployer.java:106) [java] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:184) [java] at org.codehaus.cargo.maven2.DeployerRedeployMojo.performDeployerActionOnSingleDeployable(DeployerRedeployMojo.java:49) [java] at org.codehaus.cargo.maven2.AbstractDeployerMojo.performDeployerActionOnAllDeployables(AbstractDeployerMojo.java:165) [java] at org.codehaus.cargo.maven2.AbstractDeployerMojo.doExecute(AbstractDeployerMojo.java:96) [java] at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:436) [java] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134) [java] ... 21 more [java] Caused by: org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: HTTP/1.1 200 OK [java] Date: Wed, 30 Sep 2015 10:27:52 GMT [java] Server: Apache-Coyote/1.1 [java] Pragma: No-cache [java] Cache-Control: no-cache [java] Expires: Thu, 01 Jan 1970 01:00:00 GMT [java] Content-Type: text/plain;charset=utf-8 [java] Connection: close [java] Transfer-Encoding: chunked [java] 42 [java] OK - Deployed application at context path /mywebapp [java] 0 [java] at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:715) [java] at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deployImpl(TomcatManager.java:760) [java] at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deploy(TomcatManager.java:312) [java] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.deploy(AbstractTomcatManagerDeployer.java:101) [java] ... 27 more

I'm using mod_proxy and tomcat. The source code at line 715 of org.codehaus.cargo.container.tomcat.internal.TomcatManager is:

1 2 3 4 if (!response.startsWith("OK -")) { throw new TomcatManagerException(response); }

But my response is "HTTP/1.1 200 OK", instead of "OK -....".

Status

Assignee

S. Ali Tokmen

Reporter

S. Ali Tokmen

Components

Fix versions

Affects versions

1.4.16

Priority

Major