# Let Nextcloud's API for /.well-known URIs handle all other # requests by passing them to the front-end controller. return 301 /index.php$requesturi; }
Ale gryzie się z tym (to niżej działa jesli zakomentuje to, co jest wyżej):
Dzisiaj mija 20 rocznica przystąpienia Polski do UE. Unia realnie zmieniła moje życie. Nie wyobrażam sobie Polski poza UE. Zaplusuj, jesli się za mną zgadzasz.
location ^~ /.well-known {
# The rules in this block are an adaptation of the rules
# in
.htaccess
that concern/.well-known
.location = /.well-known/carddav { return 301 /remote.php/dav/; }
location = /.well-known/caldav { return 301 /remote.php/dav/; }
location /.well-known/acme-challenge { tryfiles $uri $uri/ =404; }
location /.well-known/pki-validation { tryfiles $uri $uri/ =404; }
##NIE DZIAŁA, powinno weryfikować domenę, webroot
location = /.well-known/acme-challenge { allow all; defaulttype "text/plain"; root /usr/share/nginx/html; }
# Let Nextcloud's API for
/.well-known
URIs handle all other# requests by passing them to the front-end controller.
return 301 /index.php$requesturi;
}
Ale gryzie się z tym (to niżej działa jesli zakomentuje to, co jest wyżej):
location ~ /\.well-known/acme-challenge {
allow all;
default_type "text/plain";
root /usr/share/nginx/html;
}
Jak połączyć te dwie reguły w jeden DIZAŁAJĄCY blok?
#linux #nginx #sysadmin