Configuring Tomcat to NOT use webapps directory

Discussion in 'Java' started by Dean Rettig, Dec 19, 2003.

  1. Dean Rettig

    Dean Rettig Guest

    currently my webapps directory is something like:

    C:\java\netbeans3.5.1\tomcat406\webapps

    This is where the Netbeans install put it. I want to move the
    directory to something a little more convenient to work with like:

    c:\webapps

    All I can find in the Tomcat configuration file is:

    <Host name="localhost" debug="0" appBase="webapps" unpackWARs="true">

    but if I change appBase to anything like "c:\webapps" or "c:/webapps"
    it doesn't work. Can anybody tell me how to move the appBase
    directory outside of the Tomcat or Netbean directory?

    Thanks in advance.
    Dean
    Dean Rettig, Dec 19, 2003
    #1
    1. Advertising

  2. G'Day Dean,

    The tag should read:

    <Host name="localhost" debug="0" appBase="c://webapps" unpackWARs="true">

    Note the double forward slashes after the colon.
    Eki Y. Baskoro, Dec 19, 2003
    #2
    1. Advertising

  3. Dean Rettig

    X_AWemner_X Guest

    > C:\java\netbeans3.5.1\tomcat406\webapps
    >
    > This is where the Netbeans install put it. I want to move the
    > directory to something a little more convenient to work with like:
    >
    > c:\webapps
    >
    > All I can find in the Tomcat configuration file is:
    >
    > <Host name="localhost" debug="0" appBase="webapps" unpackWARs="true">


    This works in my Tomcat4.x installation. I put this file, mywebapp.xml, to
    "{tomcat}/webapps" folder and it will use given docBase. Url is still
    http://localhost:8080/mywebapp address.

    <Context path="/mywebapp"
    docBase="c:/projects/mywebappfolder"
    debug="0"
    reloadable="true"
    crossContext="false">

    <Logger className="org.apache.catalina.logger.FileLogger"
    prefix="mywebapp_log." suffix=".txt"
    timestamp="true"/>

    </Context>
    X_AWemner_X, Dec 29, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. charly
    Replies:
    5
    Views:
    1,769
  2. Martin Eberle
    Replies:
    2
    Views:
    812
  3. PaoloCastle
    Replies:
    1
    Views:
    359
    PaoloCastle
    Apr 17, 2005
  4. WD
    Replies:
    1
    Views:
    1,956
    Raymond DeCampo
    Aug 19, 2005
  5. Replies:
    4
    Views:
    6,203
    Tor Iver Wilhelmsen
    Nov 4, 2006
Loading...

Share This Page