tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Rees" <>
Subject RE: Running JSP's w/ Apache and Tomcat
Date Fri, 01 Dec 2000 04:01:02 GMT
What you want to do is to override the root context.  Put this in your
server.xml file:

<Context path=""

Now, you'll also have to create a WEB-INF and it's corresponding
subdirectories (lib, classes, ets) under /usr/local/apache/htdocs, as well
as add a section to your Apache httpd.conf file to disallow access to that
directory like this:

<Location "/WEB-INF">
	AllowOverride None
      Order deny,allow
      deny from all

Then you should be set to go!

Coming from JServ/GnuJSP, this took a while to figure out myself.


> | I would like to set up apache and tomcat so that apache handles
> all of my
> | static html pages and all of the JSP pages are handled by tomcat....
> | basically exactly how JServ/GNUJSP works.  What do I need to add to
> | tomcat.conf/server.xml in order to get this scenario to work correctly?
> | I've been playing with different context settings and have checked all
> | available docs and faqs without any success.  With a default
> set up (simply
> | installing Tomcat, putting my jars in /lib and including tomcat.conf in
> | httpd.conf) when I try to access a jsp file that's in my
> | /usr/local/apache/htdocs dir, I get an error saying it can't be found in
> | webapps/ROOT.  Copying the file there seems to make it work,
> but then I have
> | to maintain the same file in two places because as soon as I
> remove it from
> | my apache document root, apache can no longer find the file and
> I don't even
> | get the Tomcat error.
> |
> | Anyone out there with a similar scenario?  It seems like this should be
> | fairly basic, but the included documentation on Apache/Tomcat configs is
> | sketchy at best.

View raw message