Skip to content

Commit c396721

Browse files
authored
Merge pull request #191 from HSLdevcom/fix-giravolta-caching
Try fixing cache issue by using custom rule
2 parents de25a9c + 486246c commit c396721

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

external.conf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,8 @@ location /out/tampere-api.giravolta.io/ {
283283
add_header X-Proxy-Cache $upstream_cache_status;
284284
proxy_ignore_headers X-Accel-Expires Expires Cache-Control Set-Cookie;
285285
proxy_cache_use_stale error timeout http_500 http_502 http_503 http_504;
286+
#Default caching would use the $proxy_host so we need custom rule to use request host
287+
proxy_cache_key $scheme$host$request_uri;
286288
proxy_set_header Authorization GIRAVOLTA_TAMPERE_AUTH;
287289
}
288290

@@ -298,5 +300,7 @@ location /out/vantaa-api.giravolta.io/ {
298300
add_header X-Proxy-Cache $upstream_cache_status;
299301
proxy_ignore_headers X-Accel-Expires Expires Cache-Control Set-Cookie;
300302
proxy_cache_use_stale error timeout http_500 http_502 http_503 http_504;
303+
#Default caching would use the $proxy_host so we need custom rule to use request host
304+
proxy_cache_key $scheme$host$request_uri;
301305
proxy_set_header Authorization GIRAVOLTA_VANTAA_AUTH;
302306
}

0 commit comments

Comments
 (0)