tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey V. Meledin" <>
Subject Re: tomcat context problem (php+apache+tomcat)
Date Sat, 08 Apr 2000 07:31:06 GMT

    There is my suggestions:

MD> I have an apache 1.3.12 with php 3.0.15, php2.0.1 and tomcat 3.1beta.
MD> I installed it like in the howto-file, but encountered the following problems:

MD> 1) In httpd.conf of apache, do I have to include tomcat.conf or 
MD> tomcat-apache.conf ??
MD> I want to use tomcat for jsp-only, other pages, such as static, php2 or 
MD> php3 should
MD> be executed by apache.
I only say, that if you mount a Context, then all requests are going
to Tomcat. So If you mount ApjSevount /myjsp /myjsp
Then http://host/myjsp/myphp.phtml will goes to Tomcat, that can't
understand PHP scripts. :)
So, myjsp Context is only for Servlets and JSP.

MD> 2) I have a problem setting up a context and could not find the appropriate 
MD> info
MD> neither in the manual, nor in the howto. The section about "contexts" in 
MD> the manual
MD> is too hard to follow, as is the howto.
There is a Minimalistic Users Guide. It says that full information
about contexts and Web-application structure you can find in Servlet
Specification at .
Specification describes what is Context and many other things. Read it

MD> I would greatly appreciate any help on the context problem:

MD> I want to set up tomcat to execute every file with .jsp, independent of 
MD> where the file is stored.
MD> How can I do that?
:) I tried either. For me it works only inside Context (inside
http://host/myjsp/) . May be it's possible to start it elsewhere, but
I'm not sure. Possibly you can rewrite all .jsp URIs to appropriate
URIs starting with "/myjsp".
For security reasons (correct me, please) I map examples Context like:
ApJServMount /examples/servlet /examples
ApJServMount /examples/jsp /examples
#And ad
<Location /examples/WEB-INF >
AllowOverride None
order deny,allow
deny from all

MD> 3) How can I set a virtualhost in the httpd.conf and set the documentroot 
MD> to a site containing a jsp project?
See Minimalistic Users Guide
PS: But the decision is not elegant (one JVM per Vhost), so it's way
to make several unique contexts for each Vhost and ApjServMount it
under each Vhost. (then it possible to rewrite URIs to standart
mappings, like http://vhost/jsp (this is my suggestion, only).

Alexey V. Meledin <>
> InterForge Developers Group,  St-Petersburg, Russia
> > > > > > "InterForge to Forge Ahead" > > > > > > >

View raw message