httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Hamer" <>
Subject [users@httpd] Location/LocationMatch with regexp does not apply to alias-dirs?
Date Tue, 06 Apr 2004 14:39:54 GMT
Hi all!

I'm setting up Apache 2 (2.0.47) using the jk2 connector to connect to
Tomcat which serves the JSPs. Look at the virtualhost setup below. What
I want is to tell Apache that all *.jsp and /servlet/* requests should
passed onto Tomcat (or actually the jk2 worker). A very common setup in
my opinion, however I can't get it to work with a single Location

<VirtualHost *>
  DocumentRoot /var/tomcat4/webapps/merlin/2hv
  Alias /merlin/admin /var/tomcat4/webapps/merlin/admin
  ErrorLog /var/log/apache2/2hv-error_log
  CustomLog /var/log/apache2/2hv-access_log combined
#  <Location ~ ".*/(.*\.jsp|servlet/.*)">  ## This is what I want
#  <Location ~ "/.*\.jsp"> ## This one works, but not for the alias?
  <Location "/*.jsp"> ## This works OK
    JkUriSet worker ajp13:localhost:8009

The non-regexp version works fine in all cases. However any of the
regexp versions only work if I access a *.jsp file outside the
"merlin/admin" alias, such as or . But does NOT work, it simply shows me
the JSP source.

What am I doing wrong? Any help would be appreciated!

Paul Hamer

Head System Development
2HV Solutions

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message