Update nginx.conf

master
Edwin Lyon 4 years ago committed by GitHub
parent 5375a3afba
commit d1e0dfad9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 33
      nginx/nginx.conf

@ -26,27 +26,28 @@ http {
include /etc/nginx/mime.types; include /etc/nginx/mime.types;
default_type application/octet-stream; default_type application/octet-stream;
map $sent_http_content_type $content_security_policy { # Optional mapping rules
~*text/(html|javascript)|application/pdf|xml "default-src 'self'; base-uri 'none'; form-action 'self'; frame-ancestors 'none'; upgrade-insecure-requests"; #map $sent_http_content_type $content_security_policy {
} # ~*text/(html|javascript)|application/pdf|xml "default-src 'self'; base-uri 'none'; form-action 'self'; frame-ancestors 'none'; upgrade-insecure-requests";
#}
map $sent_http_content_type $referrer_policy { #map $sent_http_content_type $referrer_policy {
~*text/(css|html|javascript)|application\/pdf|xml "strict-origin-when-cross-origin"; # ~*text/(css|html|javascript)|application\/pdf|xml "strict-origin-when-cross-origin";
} #}
map $sent_http_content_type $cors { #map $sent_http_content_type $cors {
#Images #Images
~*image/ "*"; # ~*image/ "*";
#Web fonts #Web fonts
~*font/ "*"; # ~*font/ "*";
~*application/vnd.ms-fontobject "*"; # ~*application/vnd.ms-fontobject "*";
~*application/x-font-ttf "*"; # ~*application/x-font-ttf "*";
~*application/font-woff "*"; # ~*application/font-woff "*";
~*application/x-font-woff "*"; # ~*application/x-font-woff "*";
~*application/font-woff2 "*"; # ~*application/font-woff2 "*";
} #}
## ##
# SSL Settings # SSL Settings

Loading…
Cancel
Save