Proxy pass based on IP?

Is it possible to proxy pass a location based in source IP??

On Thu, Oct 29, 2009 at 12:16:02AM +0200, Iantcho Vassilev wrote:

Is it possible to proxy pass a location based in source IP??

There is a limited solution:

map $remote_addr $backend {
default one;
192.168.1.1 two;
192.168.1.2 two;
}

location / {
    proxy_pass  htttp://$backend$request_uri;
}

No…my point is this:

i have

location / {
root …
index… …
if ($remote_addr = “xxxxxxxxxx”" {
proxy_pass HERE
}
}

location ~ .php
{
fasct_cgi …

}

2009/10/29 Igor S. [email protected]