I have problem with php-fpm it run every file also direcotry index not working...
here is how my virtula host look loke:
Code:
<VirtualHost *:80>
ServerName example
ServerAlias example.com $
ServerAdmin example@example.com
DocumentRoot "/home/example/public_html"
ErrorLog "/home/example/logs"
CustomLog "/home/example/logs1.log" combined
ScriptAlias /cgi-bin/ /home/example/cgi-bin/
Alias /phpmyadmin /home/phpmyadmin
<IfModule mod_fastcgi.c>
<FilesMatch \.php$>
AddHandler php-fastcgi .php
Action php-fastcgi /etc/httpd/php/sbin/php-fpm.fcgi
SetHandler php-script
</FilesMatch>
FastCgiExternalServer /home/example/public_html -host 127.0.0.1:9002
Alias /etc/httpd/php/sbin/php-fpm.fcgi /etc/httpd/php/sbin/php-fpm
DirectoryIndex index.php index.shtml index.cgi index.html index.htm
Options +Indexes +FollowSymLinks +ExecCGI +Includes +MultiViews
</IfModule>
<Directory "/home/example/public_html">
AllowOverride All
Order allow,deny
Allow from all
DirectoryIndex index.php index.html index.htm default.htm
</Directory>
<Directory "/home/phpmyadmin">
AllowOverride All
Order allow,deny
Allow from all
DirectoryIndex index.php index.html index.htm default.htm
Options -Indexes
</Directory>
</VirtualHost>
and here is php-fpm pool:
Code:
; OUR CUSTOM SETTINGS
listen = 127.0.0.1:9002
;prefix = /home/example
;chroot = $prefix
; DEFAULT DEBIAN SETTINGS
;chdir = /public_html
user = example
group = example
listen.owner = example
listen.group = example
pm = dynamic
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3
security.limit_extensions = .php .php3 .php4 .php5