Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-65214

war file deployment to tomcat failed from jenkins pipeline

XMLWordPrintable

      I have installed jenkins, and tomcat in my cluster. Both are running in a different pods.

      I'm trying to deploy war file to tomcat from jenkins pipeline, but unfortunately I'm getting failed to deploy. 

      Here's my conf and log details,
      [DeployPublisher][INFO] Attempting to deploy 1 war file(s)
      [DeployPublisher][INFO] Deploying /var/jenkins_home/workspace/dummy_check_up/target/konakart.war to container Tomcat 8.x Remote with context konakart
      [/var/jenkins_home/workspace/dummy_check_up/target/konakart.war] is not deployed. Doing a fresh deployment.
      Deploying [/var/jenkins_home/workspace/dummy_check_up/target/konakart.war][Pipeline] }[Pipeline] // withEnv[Pipeline] }[Pipeline] // stage[Pipeline] }[Pipeline] // withEnv[Pipeline] }[Pipeline] // withEnv[Pipeline] }[Pipeline] // node[Pipeline] End of Pipelineorg.codehaus.cargo.container.ContainerException: Failed to deploy [/var/jenkins_home/workspace/dummy_check_up/target/konakart.war]
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.deploy(AbstractTomcatManagerDeployer.java:104)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:172)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
      at hudson.FilePath.act(FilePath.java:1164)
      at hudson.FilePath.act(FilePath.java:1147)
      at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
      at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
      at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:99)
      at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:69)
      at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)
      Caused by: java.io.IOException: Error writing request body to server
      at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.checkError(HttpURLConnection.java:3597)
      at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:3580)
      at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
      at java.io.BufferedOutputStream.write(BufferedOutputStream.java:126)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.pipe(TomcatManager.java:827)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:574)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deployImpl(TomcatManager.java:767)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deploy(TomcatManager.java:312)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.deploy(AbstractTomcatManagerDeployer.java:99)
      ... 18 more
      java.io.IOException: Error writing request body to server
      at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.checkError(HttpURLConnection.java:3597)
      at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:3580)
      at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
      at java.io.BufferedOutputStream.write(BufferedOutputStream.java:126)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.pipe(TomcatManager.java:827)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:574)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deployImpl(TomcatManager.java:767)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.deploy(TomcatManager.java:312)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.deploy(AbstractTomcatManagerDeployer.java:99)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:172)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
      at hudson.FilePath.act(FilePath.java:1164)
      at hudson.FilePath.act(FilePath.java:1147)
      at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
      at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
      at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:99)
      at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:69)
      at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)
      Finished: FAILURE
       

      Pipeline script --> deploy adapters: [tomcat8(credentialsId: 'tomcatpod', path: '', url: 'http://**.***.**.***:30010/')], contextPath: 'konakart', war: '*/.war'

       

      Somebody help me to sort out the issue here.

            Unassigned Unassigned
            chiducaf chella
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: