Fix Caddy prod: use php_fastcgi instead of reverse_proxy for PHP-FPM
PHP-FPM speaks FastCGI protocol, not HTTP. Caddy must use php_fastcgi directive with file_server and try_files for proper Symfony routing. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -19,11 +19,13 @@ ticket.e-cosplay.fr {
|
||||
}
|
||||
|
||||
handle {
|
||||
reverse_proxy localhost:4578 localhost:4579 {
|
||||
root * /var/www/e-ticket/public
|
||||
php_fastcgi localhost:4578 localhost:4579 {
|
||||
lb_policy round_robin
|
||||
health_uri /
|
||||
health_interval 10s
|
||||
trusted_proxies private_ranges
|
||||
}
|
||||
file_server
|
||||
try_files {path} /index.php?{query}
|
||||
}
|
||||
|
||||
encode gzip
|
||||
|
||||
Reference in New Issue
Block a user