diff --git a/conf/nginx.conf b/conf/nginx.conf index ba0a2dc..83454c6 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -1,18 +1,17 @@ #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; location __PATH__/ { + alias __FINALPATH__/; if ($scheme = http) { rewrite ^ https://$server_name$request_uri? permanent; } - more_set_headers Access-Control-Allow-Origin *; - index index.php; - try_files $uri $uri/ /index.php; + #try_files $uri $uri/ /index.php; location ~ [^/]\.php(/|$) { - include snippets/fastcgi-php.conf; + fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm__NAME__.sock; include fastcgi_params; fastcgi_param REMOTE_USER $remote_user; @@ -32,7 +31,6 @@ location __PATH__/ { proxy_redirect off; } - # Include SSOWAT user panel. + # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc; - }