Skip to content
This repository was archived by the owner on May 14, 2020. It is now read-only.

Commit 3214f9f

Browse files
committed
Reduced cache timing values.
1 parent 58e79f8 commit 3214f9f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/Handler/templates/nginx_default.conf.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -240,8 +240,8 @@
240240
}
241241

242242
location ~ __config\.js {
243-
expires 30m;
244-
add_header "Cache-Control" "public, max-age=1800";
243+
expires 3m;
244+
add_header "Cache-Control" "public, max-age=180";
245245
try_files $uri =404;
246246
}
247247

@@ -252,8 +252,8 @@
252252
}
253253

254254
location ~* \.(js|css|json|map|xml)$ {
255-
expires 1d;
256-
add_header "Cache-Control" "public, must-revalidate, max-age=86400";
255+
expires 2h;
256+
add_header "Cache-Control" "public, must-revalidate, max-age=7200";
257257
try_files $uri =404;
258258
}
259259

@@ -298,7 +298,7 @@
298298
# need to redefine $request_uri if it will be "/" but $request_uri is blocked for changes
299299
set $req_uri $uri;
300300
if ($req_uri = /) {
301-
set $req_uri "/index";
301+
set $req_uri "/index";
302302
}
303303
#setting prerender as a variable forces DNS resolution since nginx caches IPs and doesnt play well with load balancing
304304
rewrite .* <?=$CDNPath?>$req_uri.html?$query_string break;

0 commit comments

Comments
 (0)