How to fix SCRIPT_NAME with PHP-FPM and Apache's mod_fastcgi?
Posted
by
Kyle MacFarlane
on Server Fault
See other posts from Server Fault
or by Kyle MacFarlane
Published on 2011-04-26T17:03:27Z
Indexed on
2012/09/03
21:40 UTC
Read the original article
Hit count: 227
I have the following in my Apache conf to get PHP-FPM working:
FastCgiExternalServer /srv/www/fast-cgi-fake-handler -host 127.0.0.1:9000
AddHandler php-fastcgi .php
AddType text/html .php
Action php-fastcgi /var/www/cgi-bin
Alias /var/www/cgi-bin /srv/www/fast-cgi-fake-handler
DirectoryIndex index.php
This works fine except that SCRIPT_NAME is always /var/www/cgi-bin
and some scripts use SCRIPT_NAME to work out the location of the current script (vBulletin).
Google has plenty of solutions for Nginx but not a word for Apache.
© Server Fault or respective owner