Skip to content

Instantly share code, notes, and snippets.

@jeromenerf
Created July 2, 2015 13:12
Show Gist options
  • Save jeromenerf/4a855cdf4925a546fb9f to your computer and use it in GitHub Desktop.
Save jeromenerf/4a855cdf4925a546fb9f to your computer and use it in GitHub Desktop.
vcl 4.0;
import std;
backend default {
.host = "127.0.0.1";
.port = "1313";
}
backend front_api {
.host = "127.0.0.1";
.port = "1313";
}
sub vcl_recv {
if ( req.method != "GET") { return (pass); }
set req.backend_hint = front_api;
}
sub vcl_backend_response {
set beresp.ttl = 10s;
set beresp.grace = 20s;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment