Apache Tomcat under Windows: Changing webapps default directory
        Posted  
        
            by Maerch
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Maerch
        
        
        
        Published on 2009-01-30T13:14:37Z
        Indexed on 
            2010/05/20
            6:30 UTC
        
        
        Read the original article
        Hit count: 501
        
I am deploying my Java application with Ant. Unfortunately my test deployment on the local machine doesn't work because of Vista. The Program Files directionaries are protected and i don't want to start Ant or Eclipse as an Admin. So i had the idea to move my webapps folder to a workspace subfolder, so i can use relative paths in Ant as well.
The solutions seems to be to modify the Host element in the server.xml. With Linux it isn't such a deal:
  <Host name="localhost"  appBase="/path/to/webapps"
        unpackWARs="true" autoDeploy="true"
        xmlValidation="false" xmlNamespaceAware="false">
But with Windows i don't get it right. I tried every possible combinations i could imagine, like:
      C://Users//maerch//Workspaces//Tomcat6.0_webapps
      C:/Users/maerch/Workspaces/Tomcat6.0_webapps
      C:\Users\maerch\Workspaces\Tomcat6.0_webapps
      C:\\Users\\maerch\\Workspaces\\Tomcat6.0_webapps
      C://Users//maerch//Workspaces//Tomcat6.0_webapps\\
      C:/Users/maerch/Workspaces/Tomcat6.0_webapps/
      C:\Users\maerch\Workspaces\Tomcat6.0_webapps\
      C:\\Users\\maerch\\Workspaces\\Tomcat6.0_webapps\\
The path is also correct, but it doesn't work. There are also no error messages in the log files neither the browser shows a 404 message or anything else. Just a white page without title and so on. Can anyone help?
© Stack Overflow or respective owner