diff --git a/scripts/http_host/nginx_sync/nginx_sync.py b/scripts/http_host/nginx_sync/nginx_sync.py index 8663da0..dd0d066 100755 --- a/scripts/http_host/nginx_sync/nginx_sync.py +++ b/scripts/http_host/nginx_sync/nginx_sync.py @@ -34,6 +34,9 @@ def cli(): location /{area}/{version}/ {{ # trailing hash important alias {subdir}/; # trailing hash important try_files $uri @empty; + + add_header Cache-Control public; + expires 10y; }} """ diff --git a/scripts/http_host/nginx_sync/nginx_template.conf b/scripts/http_host/nginx_sync/nginx_template.conf index d943c43..6b065ec 100644 --- a/scripts/http_host/nginx_sync/nginx_template.conf +++ b/scripts/http_host/nginx_sync/nginx_template.conf @@ -13,5 +13,8 @@ server { location @empty { default_type application/vnd.mapbox-vector-tile; return 200 ''; + + add_header Cache-Control public; + expires 10y; } }