diff --git a/root-files/opt/flownative/lib/nginx-legacy.sh b/root-files/opt/flownative/lib/nginx-legacy.sh index 231459e..86a0f93 100644 --- a/root-files/opt/flownative/lib/nginx-legacy.sh +++ b/root-files/opt/flownative/lib/nginx-legacy.sh @@ -191,9 +191,9 @@ EOM # pass persistent resource requests to GCS location ~* "^${BEACH_PERSISTENT_RESOURCES_BASE_PATH}([a-f0-9]{40})/" { resolver 8.8.8.8; - expires ${NGINX_STATIC_FILES_LIFETIME}; proxy_set_header Authorization ""; add_header Via 'Beach Asset Proxy'; + add_header Cache-Control 'public, max-age=${NGINX_STATIC_FILES_LIFETIME}'; ${addHeaderStrictTransportSecurity} proxy_pass http://storage.googleapis.com/${BEACH_GOOGLE_CLOUD_STORAGE_PUBLIC_BUCKET}/\$1\$is_args\$args; } diff --git a/root-files/opt/flownative/lib/nginx.sh b/root-files/opt/flownative/lib/nginx.sh index 7716b33..fe4772e 100755 --- a/root-files/opt/flownative/lib/nginx.sh +++ b/root-files/opt/flownative/lib/nginx.sh @@ -38,7 +38,7 @@ export NGINX_CACHE_BACKGROUND_UPDATE="${NGINX_CACHE_BACKGROUND_UPDATE:-off}" export NGINX_CUSTOM_ERROR_PAGE_CODES="${NGINX_CUSTOM_ERROR_PAGE_CODES:-500 501 502 503}" export NGINX_CUSTOM_ERROR_PAGE_TARGET="${NGINX_CUSTOM_ERROR_PAGE_TARGET:-}" -export NGINX_STATIC_FILES_LIFETIME=${NGINX_STATIC_FILES_LIFETIME:-30d} +export NGINX_STATIC_FILES_LIFETIME=${NGINX_STATIC_FILES_LIFETIME:-6M} export PATH="${PATH}:${NGINX_BASE_PATH}/bin" EOF