javatomcatwar

How to deploy a war file in Tomcat 7


I have copied the sample.war file into the webapps directory of Tomcat, and I can access localhost:8080.

Now how will Tomcat deploy it, I mean do I need to open it in browser? How can I access the application?


Solution

  • You can access your application from: http://localhost:8080/sample

    Deploying or redeploying of war files is automatic by default - after copying/overwriting the file sample.war, check your webapps folder for an extracted folder sample.

    If it doesn't open properly, check the log files (e.g. tomcat/logs/catalina.out) for problems with deployment.