Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

netbeans 7.4 tomcat7: when deploying, where is the war file?

just created a very simple web application using netbeans. i was able to add tomcat 7 server and able to build and deploy. the web application works. my question is i thought when i did the "deploy", i was expecting my application's war file to be in the tomcat's webapps folder. i didn't see it. Tomcat's manager application does show it and i can run the application from it as well. Should i just deploy the war file manually using tomcat manager app?

Thanks in advance,

Thomas.

like image 817
ThomasDKim Avatar asked Jan 25 '14 18:01

ThomasDKim


1 Answers

NetBeans doesn't create a war file when you run deploy. It just registers the "build" directory as a webapplication with Tomcat.

Check out $CATALINA_HOME/conf/Catalina/localhost there should be a file yourapp.xml Where yourapp is the "context path" you specified for your project ("Project Properties -> Run")

The XML file contains only single entry, something like this:

<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" docBase="/path/to/your/project/build/web" path="/yourapp"/>

Due to this configuration file, Tomcat is able to run your web application

like image 165
a_horse_with_no_name Avatar answered Oct 12 '22 05:10

a_horse_with_no_name