Set DOCUMENT_ROOT correctly to make .user.ini files work recursively
This commit is contained in:
@ -65,6 +65,7 @@ server {
|
|||||||
try_files $uri $uri/ =404;
|
try_files $uri $uri/ =404;
|
||||||
location ~ \.php$ {
|
location ~ \.php$ {
|
||||||
include snippets/fastcgi-php.conf;
|
include snippets/fastcgi-php.conf;
|
||||||
|
fastcgi_param DOCUMENT_ROOT /html;
|
||||||
fastcgi_param SCRIPT_FILENAME /html$fastcgi_script_name;
|
fastcgi_param SCRIPT_FILENAME /html$fastcgi_script_name;
|
||||||
fastcgi_pass unix:/var/run/php/7.3-hosting;
|
fastcgi_pass unix:/var/run/php/7.3-hosting;
|
||||||
}
|
}
|
||||||
@ -72,6 +73,7 @@ server {
|
|||||||
location /squirrelmail {
|
location /squirrelmail {
|
||||||
location ~ \.php$ {
|
location ~ \.php$ {
|
||||||
include snippets/fastcgi-php.conf;
|
include snippets/fastcgi-php.conf;
|
||||||
|
fastcgi_param DOCUMENT_ROOT $document_root;
|
||||||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||||||
fastcgi_pass unix:/var/run/php/7.3-squirrelmail;
|
fastcgi_pass unix:/var/run/php/7.3-squirrelmail;
|
||||||
}
|
}
|
||||||
@ -80,6 +82,7 @@ server {
|
|||||||
root /usr/share;
|
root /usr/share;
|
||||||
location ~ \.php$ {
|
location ~ \.php$ {
|
||||||
include snippets/fastcgi-php.conf;
|
include snippets/fastcgi-php.conf;
|
||||||
|
fastcgi_param DOCUMENT_ROOT /html;
|
||||||
fastcgi_param SCRIPT_FILENAME /html$fastcgi_script_name;
|
fastcgi_param SCRIPT_FILENAME /html$fastcgi_script_name;
|
||||||
fastcgi_pass unix:/run/php/7.3-phpmyadmin;
|
fastcgi_pass unix:/run/php/7.3-phpmyadmin;
|
||||||
}
|
}
|
||||||
@ -88,6 +91,7 @@ server {
|
|||||||
root /usr/share/adminer;
|
root /usr/share/adminer;
|
||||||
location ~ \.php$ {
|
location ~ \.php$ {
|
||||||
include snippets/fastcgi-php.conf;
|
include snippets/fastcgi-php.conf;
|
||||||
|
fastcgi_param DOCUMENT_ROOT $document_root;
|
||||||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||||||
fastcgi_pass unix:/run/php/7.3-adminer;
|
fastcgi_pass unix:/run/php/7.3-adminer;
|
||||||
}
|
}
|
||||||
@ -398,6 +402,8 @@ function rewrite_nginx_config(PDO $db){
|
|||||||
$php_location="
|
$php_location="
|
||||||
location ~ [^/]\.php(/|\$) {
|
location ~ [^/]\.php(/|\$) {
|
||||||
include snippets/fastcgi-php.conf;
|
include snippets/fastcgi-php.conf;
|
||||||
|
fastcgi_param DOCUMENT_ROOT /www;
|
||||||
|
fastcgi_param SCRIPT_FILENAME /www\$fastcgi_script_name;
|
||||||
fastcgi_pass unix:/run/php/$tmp[system_account];
|
fastcgi_pass unix:/run/php/$tmp[system_account];
|
||||||
}";
|
}";
|
||||||
}else{
|
}else{
|
||||||
|
Reference in New Issue
Block a user