diff --git modules/varnish/templates/upload-frontend.inc.vcl.erb modules/varnish/templates/upload-frontend.inc.vcl.erb index ccf56645e7..abfb695b07 100644 --- modules/varnish/templates/upload-frontend.inc.vcl.erb +++ modules/varnish/templates/upload-frontend.inc.vcl.erb @@ -340,6 +340,13 @@ sub cluster_fe_miss { } call cluster_fe_ratelimit; + + // For WME HEAD reqs to upload, if initial lookup results in a cache miss + // (no existing object to satisfy locally), convert to pass-mode to send + // the HEAD to ATS directly and not attempt caching any result. + if (req.http.X-Client-IP == "3.211.48.168" && req.http.Host == "upload.wikimedia.org" && req.http.User-Agent ~ "^WME/[0-9]" && req.method == "HEAD") { + return (pass); + } }