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] Doing redirects based on client address
Date Fri, 06 Jan 2006 18:59:34 GMT
On 1/6/06, Rob Tanner <rtanner@linfield.edu> wrote:
> Hi,
>
> I'm try to figure out how to do a redirect based on the client's IP
> address but a search for examples has turned up nothing.
>
> Basically, I have two campuses, A and B, connected by a WAN link.  Our
> concern is service pack updates because they're huge and the link is
> small.  Therefore, if someone on campus A tries to download the link
> from the server on campus B, I want them to be redirected to campus A's
> server, and vice versa for clients on campus B.
>
> Does anyone have any configuration examples?

See "Redirect Homedirs For Foreigners" under
http://httpd.apache.org/docs/2.2/misc/rewriteguide.html
You'll probably want to replace %{REMOTE_HOST} with %{REMOTE_ADDR}.

Joshua.
Mime
View raw message