merlinsilk
Verified User
- Joined
- Feb 16, 2009
- Messages
- 32
On my centos 7 system I have apache running using php-fpm70 - and that works fine.
But I have now also installed nginx (listening on a different port) and would like the already installed and working php-fpm server.
My idea had been to create a user nginx, group nginx in DA which would give me a full setup with apache and php-fpm listening on the unix socket /usr/local/php70/sockets/nginx.sock
I set ownership of that socket to nginx:nginx with the idea that nginx runs as user nginx.
In /usr/local/directadmin/data/users/nginx/php/php-fpm70.conf I set
listen = /usr/local/php70/sockets/nginx.sock
listen.owner = nginx
listen.group = nginx
listen.mode = 660
and restarted php-fpm70
Then, in the nginx configuration I set
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass unix:/usr/local/php70/sockets/nginx.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
and smugly - after restarting nginx - tried to display a PHP file - - - - - - but nothing!
Any idea what I am doing wrong would be very much appreciated
Thanks - Merlin
But I have now also installed nginx (listening on a different port) and would like the already installed and working php-fpm server.
My idea had been to create a user nginx, group nginx in DA which would give me a full setup with apache and php-fpm listening on the unix socket /usr/local/php70/sockets/nginx.sock
I set ownership of that socket to nginx:nginx with the idea that nginx runs as user nginx.
In /usr/local/directadmin/data/users/nginx/php/php-fpm70.conf I set
listen = /usr/local/php70/sockets/nginx.sock
listen.owner = nginx
listen.group = nginx
listen.mode = 660
and restarted php-fpm70
Then, in the nginx configuration I set
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass unix:/usr/local/php70/sockets/nginx.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
and smugly - after restarting nginx - tried to display a PHP file - - - - - - but nothing!
Any idea what I am doing wrong would be very much appreciated
Thanks - Merlin