httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Bowman <ebow...@boboco.ie>
Subject [users@httpd] redirects conundrum
Date Fri, 12 Sep 2008 14:06:32 GMT
Hi,

I'm struggling a bit with mod_alias, wondering if someone can help.

I have the following configuration, running against httpd 2.2.6

<Location /balancer-manager>
    SetHandler balancer-manager
    Order Deny,Allow
    Deny from all
    Allow from all
</Location>

<VirtualHost *:80>
    ServerName example.com
    ServerAlias *.example.com

    DocumentRoot "/var/www/htdocs"
    <Directory "/var/www/htdocs">
        Options FollowSymLinks
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>
   
    Redirect permanent /a http://example.com/a/
    Redirect permanent /foo http://example.com/a
    Redirect permanent /login http://example.com/a/login
    Redirect permanent / http://example.com/a/

    ProxyPass /bar balancer://barcluster stickysession=BARID
    ProxyPassReverse /bar http://192.168.123.210:35600/bar
    ProxyPassReverse /bar http://192.168.123.226:35600/bar
    ProxyPassReverse /bar http://192.168.123.227:35600/bar
    <proxy balancer://barcluster>
        BalancerMember http://192.168.123.210:35600/bar loadfactor=1
route=210
        BalancerMember http://192.168.123.226:35600/bar loadfactor=1
route=226
        BalancerMember http://192.168.123.227:35600/bar loadfactor=1
route=227
    </proxy>

    ProxyPass /bar !
    ProxyPass /a/ balancer://foocluster/
    ProxyPassReverse /a http://192.168.123.226:35640/foo/
    <proxy balancer://foocluster>
        BalancerMember http://192.168.123.226:35640/foo/ loadfactor=1
    </proxy>
</VirtualHost>


In a nutshell, requests to /bar go to to one cluster, and basically
"/everything%20else" gets redirected to "/a/everything%20else", and sent
to a separate cluster.  We need this behaviour.

What I'm wondering is, how can I prevent /balancer-manager from
redirecting to /a/balancer-manager?  I've tried everything obvious, and
the only way I can make it work is to remove the line "Redirect
permanent / http://example.com/a/" which breaks everything else.

Is there a way to prevent /balancer-manager from redirecting similar to
how /bar doesn't redirect, but without proxying?

Thanks in advance,
Eric

-- 
Eric Bowman
Boboco Ltd
ebowman@boboco.ie
http://www.boboco.ie/ebowman/pubkey.pgp
+35318394189/+353872801532


---------------------------------------------------------------------
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