From a82b95a28fc97760f3272fa44716d71c2e25519f Mon Sep 17 00:00:00 2001 From: Marc Mintel Date: Thu, 5 Feb 2026 22:41:26 +0100 Subject: [PATCH] feat: Adjust backend timeouts, add `/cms` to cache bypass, and include `X-Backend-IP` in responses. --- varnish/default.vcl | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/varnish/default.vcl b/varnish/default.vcl index 80aad677..08e61269 100644 --- a/varnish/default.vcl +++ b/varnish/default.vcl @@ -5,7 +5,9 @@ import std; backend default { .host = "klz-app"; .port = "3000"; - .first_byte_timeout = 60s; + .connect_timeout = 5s; + .first_byte_timeout = 90s; + .between_bytes_timeout = 5s; } acl purge { @@ -27,8 +29,8 @@ sub vcl_recv { return (pass); } - # Bypass cache for Gatekeeper and Directus (already handled by Traefik, but safe to be explicit) - if (req.url ~ "^/gatekeeper" || req.url ~ "^/directus" || req.url ~ "^/admin") { + # Bypass cache for Gatekeeper, Directus and CMS proxy + if (req.url ~ "^/gatekeeper" || req.url ~ "^/directus" || req.url ~ "^/admin" || req.url ~ "^/cms") { return (pass); }