location LOCATIONTOCHANGE { alias ALIASTOCHANGEfiles/; index index.php index.html index.htm; default_type text/html; client_max_body_size 1G; location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php5-fpm-NAMETOCHANGE.sock; fastcgi_index index.php; include fastcgi_params; fastcgi_param REMOTE_USER $remote_user; fastcgi_param PATH_INFO $fastcgi_path_info; fastcgi_param SCRIPT_FILENAME $request_filename; } # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc; } # Admin location - DO NOT EDIT location PATHTOCHANGE/admin/_assets { alias /var/www/my_webapp/_assets/; } location PATHTOCHANGE/admin { alias /var/www/my_webapp/; client_max_body_size 10G; location ~ ^PATHTOCHANGE/admin$ { rewrite ^(.*) $1/ redirect; } location ~ ^PATHTOCHANGE/admin/ { fastcgi_split_path_info ^(PATHTOCHANGE/admin)(/?.*)$; fastcgi_pass unix:/var/run/php5-fpm-NAMETOCHANGE.sock; include fastcgi_params; fastcgi_param REMOTE_USER $remote_user; fastcgi_param PATH_INFO $fastcgi_path_info; fastcgi_param SCRIPT_FILENAME ALIASTOCHANGEadmin.php; } # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc; }