From e99fa9433e62559c9aa3b11d3c4b29e435590413 Mon Sep 17 00:00:00 2001 From: andryyy Date: Wed, 14 Jun 2017 23:10:50 +0200 Subject: [PATCH] Fix dav url detection for apple --- data/conf/nginx/site.conf | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/data/conf/nginx/site.conf b/data/conf/nginx/site.conf index ef6ec1073..cda034108 100644 --- a/data/conf/nginx/site.conf +++ b/data/conf/nginx/site.conf @@ -28,7 +28,7 @@ server { } location ^~ /.well-known/acme-challenge/ { - allow all; + allow all; default_type "text/plain"; } @@ -37,9 +37,8 @@ server { real_ip_header X-Forwarded-For; real_ip_recursive on; - location = /principals/ { - rewrite ^ $client_req_scheme://$http_host/SOGo/dav; - allow all; + location ^~ /principals { + return 301 /SOGo/dav; } location ~ \.php$ { @@ -173,7 +172,7 @@ server { } location ^~ /.well-known/acme-challenge/ { - allow all; + allow all; default_type "text/plain"; } @@ -182,9 +181,8 @@ server { real_ip_header X-Forwarded-For; real_ip_recursive on; - location = /principals/ { - rewrite ^ $client_req_scheme://$http_host/SOGo/dav; - allow all; + location ^~ /principals { + return 301 /SOGo/dav; } location ~ \.php$ {