You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Luis Torres <A0...@itesm.mx> on 2005/07/08 02:53:52 UTC

Mapping everything to Tomcat? (mod_jk)

Hello Everyone, first post to the list  =)

I have a test setup with Solaris 9, Apache 2.043, mod_jk and two tomcats 
(4.131 & JDK 1.5.0)

To have the Tomcats handling the applications, first I used the 
following lines but the problem was that my jsp's where taken by tomcat 
but my images, css and other elements where served by apache, hence my 
images, styles, etc where not found by the server since they are all 
inside /webapps/app_name/images
---
Lines of httpd.conf:
JkMount /*.jsp loadbalancer
JkMount /servlet/* loadbalancer

Also, servlets never worked using this directives.

To solve this, probably in not the best manner I just passed everything 
to tomcat using (in httpd.conf):
JkMount /* loadbalancer

This worked without a glitch altough I havent done extensive testing.

So the question is... what is the best way to achieve this?? And, How 
bad can things get if I leave it like that. The server is meant to be 
used only as an apps server and not a normal web server so I'm using 
apache strictly as a front end for load balancing and all the things you 
get with mod_jk

Thanks,

Luis

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Mapping everything to Tomcat? (mod_jk)

Posted by Alan Chandler <al...@chandlerfamily.org.uk>.
On Friday 08 July 2005 01:53, Luis Torres wrote:
> Hello Everyone, first post to the list  =)
>
> I have a test setup with Solaris 9, Apache 2.043, mod_jk and two tomcats
> (4.131 & JDK 1.5.0)
>
> To have the Tomcats handling the applications, first I used the
> following lines but the problem was that my jsp's where taken by tomcat
> but my images, css and other elements where served by apache, hence my
> images, styles, etc where not found by the server since they are all
> inside /webapps/app_name/images

Use JkAutoAlias /.../webapps or just use a standard Apache Alias directive to 
map the Apache <location> around the webapps <directory> [Not sure what the 
different between JkAutoAlias and plain Alias - I just use the former]

Note also I had to jkmount /*.do to get struts to work.

-- 
Alan Chandler
http://www.chandlerfamily.org.uk

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org