httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <jos...@slive.ca>
Subject Re: [users@httpd] ProxyPass kills Alias
Date Mon, 19 Apr 2004 14:25:26 GMT

On Mon, 19 Apr 2004, Milos Prudek wrote:

> I have Apache 2.0.48 (Apache 2) and Apache 1.3.28 (Apache 1).
>
> I need to catch a specific path in an Alias directive and all the rest
> (the root folder) should be processed by a ProxyPass directive.
>
> Example:
>    Alias /hell /home/joe/hell
>    ProxyPass / http://localhost:2000/
>
> Apache 1 correctly processes this config.
>
> Apache 2 will totally ignore Alias directives if ProxyPass is present.
> It will honor Alias if I comment out ProxyPass.
>
> Anyone can confirm this is an Apache 2 error?

You can very likely get what you want by adding
ProxyPass /hell !
BEFORE the existing ProxyPass.  See:
http://httpd.apache.org/docs-2.0/mod/mod_proxy.html#proxypass

You can certainly get what you want by using mod_rewrite in place of the
ProxyPass directive to be more precise about what you want to proxy.

Whether this is a bug, I don't know.  Module ordering issues can get quite
complicated, and I'm not sure if there is a specific reason for this one.
For example, if you instead had

Alias /foo /...
ProxyPass /foo/bar /...

wouldn't you want the ProxyPass to override the Alias?

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message