Search code examples
tomcatjenkinsdeploymentwar-filedeployment

Jenkins deploy war file to Tomcat 8 - webpage show error


I am trying to deploy sample.war file to Tomcat 8 and file deployer successfully. However, when I try to launch http://localhost:8080/sample/ it show me following error on the web page: enter image description here

After deployment following is success log:

Started by user admin
Building on master in workspace C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest
[AutomatedDeploymentTest] $ cmd /c call C:\Users\name\AppData\Local\Temp\hudson6142418824859478059.bat

C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest>exit 0 
[AutomatedDeploymentTest] $ sh -xe C:\Users\name\AppData\Local\Temp\hudson3975448203686724676.sh
+ dir
sample.war
+ date
Tue, Jun 20, 2017  8:45:09 AM
Deploying C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest\sample.war to container Tomcat 7.x Remote
  Redeploying [C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest\sample.war]
  Undeploying [C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest\sample.war]
  Deploying [C:\Users\name\.jenkins\workspace\AutomatedDeploymentTest\sample.war]
Finished: SUCCESS

I am not sure why webpage is not displaying app up and running since war file deployed successfully.


Solution

  • I just launch url as http://localhost:8080/sample.war insted of http://localhost:8080/sample/ and it worked for me. I am not sure why I need to enter sample.war with extension .war but it worked finally.