Add CORS max age annotation (#1888)

Add cors-max-age annotation
This commit is contained in:
Márk Sági-Kazár 2018-01-09 12:19:42 +01:00 committed by Manuel Alejandro de Brito Fontes
parent 5973bec599
commit 313fdd2d1a
5 changed files with 22 additions and 1 deletions

View file

@ -558,7 +558,7 @@ stream {
{{ if $cors.CorsAllowCredentials }} add_header 'Access-Control-Allow-Credentials' '{{ $cors.CorsAllowCredentials }}' always; {{ end }}
add_header 'Access-Control-Allow-Methods' '{{ $cors.CorsAllowMethods }}' always;
add_header 'Access-Control-Allow-Headers' '{{ $cors.CorsAllowHeaders }}' always;
add_header 'Access-Control-Max-Age' 1728000;
add_header 'Access-Control-Max-Age' {{ $cors.CorsMaxAge }};
add_header 'Content-Type' 'text/plain charset=UTF-8';
add_header 'Content-Length' 0;
return 204;