From c666372f94a625123181af54aec47843b98d7e07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciar=C3=A1n=20Ainsworth?= Date: Mon, 18 May 2020 20:35:14 +0100 Subject: [PATCH] Fix nginx config for Chrome --- conf/nginx.conf | 33 ++++++++++++++++----------------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 6df184f..fed10bb 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -1,31 +1,30 @@ location / { - include __FINALPATH__/code/deploy/funkwhale_proxy.conf; - # this is needed if you have file import via upload enabled - client_max_body_size 100M; - proxy_pass http://127.0.0.1:__PORT__/; + include __FINALPATH__/code/deploy/funkwhale_proxy.conf; + # this is needed if you have file import via upload enabled + client_max_body_size 100M; + proxy_pass http://127.0.0.1:__PORT__/; } location /front/ { - alias __FINALPATH__/code/front/dist/; + alias __FINALPATH__/code/front/dist/; expires 30d; - more_set_headers Pragma public; - more_set_headers Cache-Control "public, must-revalidate, proxy-revalidate"; - more_set_headers Content-Security-Policy "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; font-src 'self' data:; object-src 'none'; media-src 'self' data:"; - more_set_headers Referrer-Policy "strict-origin-when-cross-origin"; - more_set_headers X-Frame-Options "SAMEORIGIN"; - more_set_headers Service-Worker-Allowed "/"; + more_set_headers "Pragma: public"; + more_set_headers "Cache-Control: public, must-revalidate, proxy-revalidate"; + more_set_headers "Content-Security-Policy: default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; font-src 'self' data:; object-src 'none'; media-src 'self' data:"; + more_set_headers "Referrer-Policy: strict-origin-when-cross-origin"; + more_set_headers "X-Frame-Options: SAMEORIGIN"; + more_set_headers "Service-Worker-Allowed: /; } location /front/embed.html { - more_set_headers Content-Security-Policy "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; font-src 'self' data:; object-src 'none'; media-src 'self' data:"; - more_set_headers Referrer-Policy "strict-origin-when-cross-origin"; - more_set_headers X-Frame-Options "ALLOW"; + more_set_headers "Content-Security-Policy: default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; font-src 'self' data:; object-src 'none'; media-src 'self' data:"; + more_set_headers "Referrer-Policy: strict-origin-when-cross-origin"; + more_set_headers "X-Frame-Options: ALLOW"; + more_set_headers "Pragma: public"; + more_set_headers "Cache-Control: public, must-revalidate, proxy-revalidate"; alias __FINALPATH__/code/front/dist/embed.html; expires 30d; - more_set_headers Pragma public; - more_set_headers Cache-Control "public, must-revalidate, proxy-revalidate"; - } location /federation/ {