wood burning stoves 2.0*
The moose likes Tomcat and the fly likes Deploying files to webapps/ROOT Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Deploying files to webapps/ROOT" Watch "Deploying files to webapps/ROOT" New topic

Deploying files to webapps/ROOT

Victor Ho
Ranch Hand

Joined: Sep 05, 2003
Posts: 74

I have had success deploying applications as .war files into webapps/. E.g. applicaiton 'xyz' -> webapps/xyz.

However, this requires the users to type the sub-dir names in the url:

If I would like to deploy files to the webapps/ROOT directly, any pointers on how to do so?

William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 12769
With a WAR you are creating a new webapplication. /ROOT is already a web application for "/" so you can dump html and jsp files in directly. If you want a servlet to run under /ROOT, you will have to modify the web.xml in /ROOT/WEB-INF.
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Deploying files to webapps/ROOT