1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/nextcloud_ynh.git synced 2024-09-03 19:55:57 +02:00

Fix subfolder installation

This commit is contained in:
Jimmy Monin 2020-02-16 10:33:19 +01:00
parent 4678cc52aa
commit 3b22e1cb02

View file

@ -70,13 +70,13 @@ location ^~ __PATH__/ {
deny all; deny all;
} }
location ~ ^__PATH__/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|oc[ms]-provider/.+)\.php(?:$|/)$ { location ~ ^__PATH__/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|oc[ms]-provider/.+)\.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;
include fastcgi_params; include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param SCRIPT_FILENAME $request_filename;
fastcgi_param PATH_INFO $path_info; fastcgi_param PATH_INFO $path_info;
fastcgi_param HTTPS on; fastcgi_param HTTPS on;
# Avoid sending the security headers twice # Avoid sending the security headers twice
@ -95,19 +95,19 @@ location ^~ __PATH__/ {
} }
location = __PATH__/core/js/oc.js { location = __PATH__/core/js/oc.js {
rewrite ^ /index.php$request_uri; rewrite ^ __PATH__/index.php$request_uri;
} }
location = __PATH__/core/preview.png { location = __PATH__/core/preview.png {
rewrite ^ /index.php$request_uri; rewrite ^ __PATH__/index.php$request_uri;
} }
location ~* ^__PATH__/(?:css|js)/ { location ~* ^__PATH__/(?:css|js)/ {
rewrite ^ /index.php$request_uri; rewrite ^ __PATH__/index.php$request_uri;
} }
location ~* ^__PATH__/apps/theming/img/core/filetypes/ { location ~* ^__PATH__/apps/theming/img/core/filetypes/ {
rewrite ^ /index.php$request_uri; rewrite ^ __PATH__/index.php$request_uri;
} }
@ -130,7 +130,7 @@ location ^~ __PATH__/ {
} }
location ~* \.(?:png|html|ttf|ico|jpg|jpeg|bcmap)$ { location ~* \.(?:png|html|ttf|ico|jpg|jpeg|bcmap)$ {
try_files $uri /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;
} }