You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Mason Jones <ma...@clipshow.com> on 2000/06/08 20:30:41 UTC
Adding new servlet context?
I've had everything running okay after initially installing Tomcat,
and I could use the text servlets. So now I want to create my own
directory under my document root to house the servlets I'll be
writing. Unfortunately, I'm finding the documentation on how to
do this to be severely lacking...hopefully someone here can help.
It should be a pretty simple process.
Let's say my document root is /web/docs and I want to create
a new directory /web/docs/javatest to house my code. I've actually
got this working for jsp classes, so I know the classpath is okay,
the WEB-INF/classes directory is working fine... So the problem
has to be with the servlet zone or context info.
I've put the context definition into the tomcat.conf file:
<Context path="/javatest" docBase="/web/docs/javatest" deb
ug="0" reloadable="true" >
</Context>
And I put the lines into server.xml:
Alias /javatest /web/docs/javatest
<Directory "/web/docs/javatest">
Options Indexes FollowSymLinks
</Directory>
ApJServMount /javatest /javatest
<Location /javatest/WEB-INF/ >
AllowOverride None
deny from all
</Location>
What else do I need to do? I'm just getting 404s when trying to
run the servlets...
Thanks in advance for any help.