nginx: only index.php needs to be sent to PHP-FPM
This commit is contained in:
parent
2e37d044ae
commit
c672af5434
1 changed files with 3 additions and 5 deletions
|
@ -7,17 +7,15 @@ location __PATH__/ {
|
|||
index index.php;
|
||||
|
||||
# Chrooted PHP-FPM
|
||||
#sub_path_only location ~ ^__PATH__(?<chroot_path>/.*\.php)$ {
|
||||
#root_path_only location ~ ^(?<chroot_path>/.*\.php)$ {
|
||||
location __PATH__/index.php {
|
||||
alias /;
|
||||
fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock;
|
||||
fastcgi_index index.php;
|
||||
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
|
||||
fastcgi_param PATH_INFO $fastcgi_path_info;
|
||||
fastcgi_param SCRIPT_FILENAME $chroot_path;
|
||||
fastcgi_param SCRIPT_FILENAME /index.php;
|
||||
include fastcgi_params;
|
||||
#sub_path_only }
|
||||
#root_path_only }
|
||||
}
|
||||
|
||||
# Security related headers
|
||||
more_set_headers "Referrer-Policy: no-referrer";
|
||||
|
|
Loading…
Add table
Reference in a new issue