mirror of
https://github.com/mempool/mempool.git
synced 2025-02-23 06:35:15 +01:00
Modify nginx.conf to cache HTML for 10m and static resources for 1h
Fixes #61
This commit is contained in:
parent
a52f98c39d
commit
d5cc558670
1 changed files with 7 additions and 0 deletions
|
@ -34,6 +34,13 @@
|
|||
# fallback for all URLs i.e. /address/foo /tx/foo /block/000
|
||||
location / {
|
||||
try_files /$lang/$uri /$lang/$uri/ $uri $uri/ /en-US/$uri @index-redirect;
|
||||
add_header Cache-Control "public, no-transform";
|
||||
expires 10m;
|
||||
}
|
||||
location /resources {
|
||||
try_files /$lang/$uri /$lang/$uri/ $uri $uri/ /en-US/$uri @index-redirect;
|
||||
add_header Cache-Control "public, no-transform";
|
||||
expires 1h;
|
||||
}
|
||||
location @index-redirect {
|
||||
add_header vary accept-language;
|
||||
|
|
Loading…
Add table
Reference in a new issue