Caddy (2.8.4) is hosting a PHP application through FastCGI (PHP-FPM) but for some reason the $_SERVER['SCRIPT_NAME']
does not contain the full path when I use the caddy handle_path
config.
:80 {
handle_path /subpath/* {
# serve a PHP site through php-fpm:
php_fastcgi localhost:9000 {
root /var/www/html
}
}
}
When I visit:
www.domain.com/subpath/ I get:
$_SERVER['SCRIPT_NAME']=/index.php
But I would like to get /subpath/index.php
How should I change the caddyfile config to achieve this?