Skip to content

Instantly share code, notes, and snippets.

@ThijsFeryn
Created January 20, 2016 13:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ThijsFeryn/f69d3bfbc262d7691577 to your computer and use it in GitHub Desktop.
Save ThijsFeryn/f69d3bfbc262d7691577 to your computer and use it in GitHub Desktop.
Send custom headers to the application to check client.ip, server.ip, local.ip & remote.ip
vcl 4.0;
backend default {
.host = "10.10.10.53";
.port = "80";
}
sub vcl_recv {
set req.http.x-clientip = client.ip;
set req.http.x-serverip = server.ip;
set req.http.x-localip = local.ip;
set req.http.x-remoteip = remote.ip;
return(pass);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment