IP pass thru

Per Buer perbu at varnish-software.com
Tue Oct 11 09:33:11 CEST 2011


Hi.
On Mon, Oct 10, 2011 at 7:11 PM, M.H. <spydergst_97 at yahoo.com> wrote:
>
> Is it possible to let clients with certain IP's pass thru to the backend and not cache using varnish?

Yes. However, what you probably want is to use an ACL rather than
matching directly against IP addresses. It's probably faster as well
(not that it would be possible to measure the difference).

acl passem {
        "192.168.55.0/24";
}


sub vcl_recv {
  (..)
  if (!(client.ip ~ passem)) {
    return(pass);
  }
(..)

}






--
Per Buer, CEO
Phone: +47 21 98 92 61 / Mobile: +47 958 39 117 / Skype: per.buer
Varnish makes websites fly!
Whitepapers | Video | Twitter




More information about the varnish-misc mailing list