From 705e2fd219f6e1964ff8ec8b3f21be4f9179f3a8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 21 Jul 2021 23:30:30 +0200 Subject: [PATCH] Update nginx.conf --- conf/nginx.conf | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 8cc846f..6bee4ff 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -24,11 +24,14 @@ location __PATH__/ { } # CORS - more_set_headers "Access-Control-Allow-Origin: '*'"; - more_set_headers "Access-Control-Max-Age: 3600"; - more_set_headers "Access-Control-Expose-Headers: Content-Length"; - more_set_headers "Access-Control-Allow-Headers: Range"; - more_set_headers "Accept-Ranges: bytes"; + location ~ .(ttf|ttc|otf|eot|woff|woff2|font.css|css|js)$ { + more_set_headers "Access-Control-Allow-Origin: '*'"; + more_set_headers "Access-Control-Max-Age: 3600"; + more_set_headers "Access-Control-Expose-Headers: Content-Length"; + more_set_headers "Access-Control-Allow-Headers: Range"; + more_set_headers "Accept-Ranges: bytes"; + root __FINALPATH__/; + } # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc;