mirror of
https://github.com/YunoHost-Apps/nextcloud_ynh.git
synced 2024-09-03 19:55:57 +02:00
fix nginx on root install
This commit is contained in:
parent
8d1bb6046b
commit
77386abeba
1 changed files with 6 additions and 6 deletions
|
@ -69,14 +69,14 @@ location ^~ __PATH__/ {
|
||||||
access_log off;
|
access_log off;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ ^\__PATH__\/(?:build|tests|config|lib|3rdparty|templates|data)\/ {
|
location ~ ^__PATH__/(?:build|tests|config|lib|3rdparty|templates|data)\/ {
|
||||||
deny all;
|
deny all;
|
||||||
}
|
}
|
||||||
location ~ ^\__PATH__\/(?:\.|autotest|occ|issue|indie|db_|console) {
|
location ~ ^__PATH__/(?:\.|autotest|occ|issue|indie|db_|console) {
|
||||||
deny all;
|
deny all;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ ^\__PATH__\/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy)\.php(?:$|\/) {
|
location ~ ^__PATH__/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy)\.php(?:$|\/) {
|
||||||
fastcgi_split_path_info ^(.+?\.php)(\/.*|)$;
|
fastcgi_split_path_info ^(.+?\.php)(\/.*|)$;
|
||||||
set $path_info $fastcgi_path_info;
|
set $path_info $fastcgi_path_info;
|
||||||
try_files $fastcgi_script_name =404;
|
try_files $fastcgi_script_name =404;
|
||||||
|
@ -94,7 +94,7 @@ location ^~ __PATH__/ {
|
||||||
fastcgi_request_buffering off;
|
fastcgi_request_buffering off;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ ^\__PATH__\/(?:updater|oc[ms]-provider)(?:$|\/) {
|
location ~ ^__PATH__/(?:updater|oc[ms]-provider)(?:$|\/) {
|
||||||
try_files $uri/ =404;
|
try_files $uri/ =404;
|
||||||
index index.php;
|
index index.php;
|
||||||
}
|
}
|
||||||
|
@ -120,7 +120,7 @@ location ^~ __PATH__/ {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Adding the cache control header for js, css and map files
|
# Adding the cache control header for js, css and map files
|
||||||
location ~ ^\__PATH__\/.+[^\/]\.(?:css|js|woff2?|svg|gif|map)$ {
|
location ~ ^__PATH__/.+[^\/]\.(?:css|js|woff2?|svg|gif|map)$ {
|
||||||
try_files $uri __PATH__/index.php$request_uri;
|
try_files $uri __PATH__/index.php$request_uri;
|
||||||
more_set_headers "Cache-Control: public, max-age=15778463";
|
more_set_headers "Cache-Control: public, max-age=15778463";
|
||||||
# Add headers to serve security related headers
|
# Add headers to serve security related headers
|
||||||
|
@ -137,7 +137,7 @@ location ^~ __PATH__/ {
|
||||||
access_log off;
|
access_log off;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ ^\__PATH__\/.+[^\/]\.(?:png|html|ttf|ico|jpg|jpeg|bcmap)$ {
|
location ~ ^__PATH__/.+[^\/]\.(?:png|html|ttf|ico|jpg|jpeg|bcmap)$ {
|
||||||
try_files $uri __PATH__/index.php$request_uri;
|
try_files $uri __PATH__/index.php$request_uri;
|
||||||
# Optional: Don't log access to other assets
|
# Optional: Don't log access to other assets
|
||||||
access_log off;
|
access_log off;
|
||||||
|
|
Loading…
Add table
Reference in a new issue