From e1a6e0644c61ced05ffbf3e601052e94d02cdeee Mon Sep 17 00:00:00 2001 From: MichiK <michik@michik.net> Date: Wed, 23 Dec 2020 17:42:03 +0100 Subject: [PATCH] Fix nginx config --- host_vars/gabriel.c3heaven.de | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/host_vars/gabriel.c3heaven.de b/host_vars/gabriel.c3heaven.de index cb6e545..5e74e8e 100644 --- a/host_vars/gabriel.c3heaven.de +++ b/host_vars/gabriel.c3heaven.de @@ -18,9 +18,9 @@ nginx_https_sites: locations: - location: "/" config: "root {{ website_deployment_path }};" - - location "/img/" + - location: "/img/" config: "add_header Access-Control-Allow-Origin *;" - - location "~ /(.*)_galf_tseuq.html$" + - location: "~ /(.*)_galf_tseuq.html$" config: "add_header Access-Control-Allow-Origin *;" - location: "~ /wiki(.*)$" config: "return 301 https://wiki.c3heaven.de$1?$args;" @@ -32,18 +32,25 @@ nginx_https_sites: add_header Access-Control-Allow-Origin *; - location: "/angelguide.pdf" config: "rewrite .* /guide/angelguide_$lang.pdf;" + - location: "/favicon.ico" + config: |- + access_log off; + log_not_found off; + return 404; - name: "www.c3heaven.de" locations: - location: "/" - config: "root /var/www/html;" - - location: "~ /wiki(.*)$" - config: "return 301 https://wiki.c3heaven.de$1?$args;" - - location: "~ /kanboard(.*)$" - config: "return 301 https://kanboard.c3heaven.de$1?$args;" + config: |- + access_log off; + log_not_found off; + return 301 https://c3heaven.de$request_uri; - name: "gabriel.c3heaven.de" locations: - location: "/" - config: "root /var/www/html;" + config: |- + access_log off; + log_not_found off; + return 301 https://c3heaven.de$request_uri; - name: "kanboard.c3heaven.de" options: - "client_max_body_size 100M;" -- GitLab