diff --git a/tesseract/genconf/nginx.go b/tesseract/genconf/nginx.go index 0b6db98..51aa6a2 100644 --- a/tesseract/genconf/nginx.go +++ b/tesseract/genconf/nginx.go @@ -23,48 +23,48 @@ const nginxTemplate = `server { location = / { try_files /index.html =404; - add_header Content-Type "text/html; charset=utf-8" always; - add_header Access-Control-Allow-Origin "*" always; + add_header Content-Type "text/html; charset=utf-8"; + add_header Access-Control-Allow-Origin "*"; } # Checkpoint endpoint - no caching location = /checkpoint { try_files /checkpoint =404; - add_header Content-Type "text/plain; charset=utf-8" always; - add_header Access-Control-Allow-Origin "*" always; - add_header Cache-Control "no-store" always; + add_header Content-Type "text/plain; charset=utf-8"; + add_header Access-Control-Allow-Origin "*"; + add_header Cache-Control "no-store"; } # Log info endpoint location = /log.v3.json { try_files /log.v3.json =404; - add_header Content-Type "application/json" always; - add_header Access-Control-Allow-Origin "*" always; - add_header Cache-Control "public, max-age=3600, immutable" always; + add_header Content-Type "application/json"; + add_header Access-Control-Allow-Origin "*"; + add_header Cache-Control "public, max-age=3600, immutable"; } # Issuer certificate endpoint - long cache location ~ ^/issuer/(.+)$ { try_files /issuer/$1 =404; - add_header Content-Type "application/pkix-cert" always; - add_header Access-Control-Allow-Origin "*" always; - add_header Cache-Control "public, max-age=604800, immutable" always; + add_header Content-Type "application/pkix-cert"; + add_header Access-Control-Allow-Origin "*"; + add_header Cache-Control "public, max-age=604800, immutable"; } # Tile data endpoint - long cache, may have gzip location ~ ^/tile/(.+)$ { try_files /tile/$1 =404; - add_header Content-Type "application/octet-stream" always; - add_header Access-Control-Allow-Origin "*" always; - add_header Cache-Control "public, max-age=604800, immutable" always; + add_header Content-Type "application/octet-stream"; + add_header Access-Control-Allow-Origin "*"; + add_header Cache-Control "public, max-age=604800, immutable"; # Gzip encoding for .gz files location ~ \.gz$ { - add_header Content-Encoding "gzip" always; + add_header Content-Encoding "gzip"; } } }