Start networking and exchanging professional insights

Register now or log in to join your professional community.

Follow

J2EE: How can i deploy a .war file to the tomcat webapps directory using netbeans?

user-image
Question added by Arslan Siddiqui , Java Team Lead , Wiztech
Date Posted: 2015/04/22
Phu Le
by Phu Le , Senior Developer , FPT Software

  1. Create a Java Web Project using Netbeans.
  2. Click on the Projects tab, or press Ctrl+1.
  3. Right-click on the project's name and click on build.
  4. Click on Files, or press Ctrl+2, to navigate to the File structure of the project.
  5. Expand the project node by double-clicking on the project's name.
  6. Right-click on build.xml.
  7. Select Run Target.
  • On Run Target's sub menu, click on dist.
The Output panel will show the path in which the WAR file is placed. Deploying the WAR file
  • Copy the WAR file and paste in the the webapps folder of your apache tomcat installation (may be‘C:\\apache-tomcat-6.0.32\\webapps’) folder
  • Then start the tomcat server by double clicking startup.bat file of your apache tomcat installation (may be‘C:\\apache-tomcat-6.0.32\\bin\\startup.bat’)
  • This will deploy and redeploy the all WAR files inside  the webapps folder
If the deployment is successful, when you run the project it will display the “Hello World” output (when you enter following URL)

More Questions Like This

Do you need help in adding the right keywords to your CV? Let our CV writing experts help you.