Add new location by default for /.well-know, fix some warning in Nextcloud check setup
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Eric Morino 2021-11-26 15:42:39 +01:00
parent 2ec026c2b3
commit 7e36d03804

View file

@ -35,20 +35,19 @@ server {
access_log off; access_log off;
} }
# The following 2 rules are only needed for the user_webfinger app. # Make a regex exception for `/.well-known` so that clients can still
# Uncomment it if you're planning to use this app. # access it despite the existence of the regex rule
rewrite ^/.well-known/host-meta /public.php?service=host-meta last; # `location ~ /(\.|autotest|...)` which would otherwise handle requests
rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json last; # for `/.well-known`.
location ^~ /.well-known {
# The following 6 rules are borrowed from `.htaccess`
# The following rule is only needed for the Social app. location = /.well-known/carddav { return 301 /remote.php/dav/; }
# Uncomment it if you're planning to use this app. location = /.well-known/caldav { return 301 /remote.php/dav/; }
rewrite ^/.well-known/webfinger /public.php?service=webfinger last; # Anything else is dynamically handled by Nextcloud
location ^~ /.well-known { return 301 /index.php$uri; }
location = /.well-known/carddav { try_files $uri $uri/ =404;
return 301 $scheme://$host:$server_port/remote.php/dav;
}
location = /.well-known/caldav {
return 301 $scheme://$host:$server_port/remote.php/dav;
} }
# set max upload size # set max upload size