Browse Source

Fix dav url detection for apple

andryyy 8 years ago
parent
commit
e99fa9433e
1 changed files with 6 additions and 8 deletions
  1. 6 8
      data/conf/nginx/site.conf

+ 6 - 8
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$ {