From eacfb9089b89016dc4c1738330c2c9b4b87d0325 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rodrigo=20Ram=C3=ADrez=20Norambuena?= Date: Mon, 3 Jun 2019 20:51:05 -0400 Subject: [PATCH] Bugfix: Fix the user/group for /etc/php-fpm.d/www.conf (#237) For a clean install of Centos 7 and using the installer php-fpm get the permission error "unix:/var/run/php-fpm/php-fpm.sock failed (13: Permission denied) while connecting to upstream" This patch the correct group and user to run php-fpm process. --- centos/resources/php.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/centos/resources/php.sh b/centos/resources/php.sh index cc887e0..15f1637 100755 --- a/centos/resources/php.sh +++ b/centos/resources/php.sh @@ -28,8 +28,8 @@ TIMEZ=$(timedatectl | grep 'Time zone' | awk '{ print $3 }') sed -ie "s#;date.timezone =#date.timezone = $TIMEZ#g" /etc/php.ini sed -ie 's/;cgi.fix_pathinfo=1/cgi.fix_pathinfo=0/g' /etc/php.ini sed -ie "s|listen = 127.0.0.1:9000|listen = /var/run/php-fpm/php-fpm.sock|g" /etc/php-fpm.d/www.conf -sed -ie 's/;listen.owner = nobody/listen.owner = nobody/g' /etc/php-fpm.d/www.conf -sed -ie 's/;listen.group = nobody/listen.group = nobody/g' /etc/php-fpm.d/www.conf +sed -ie 's/;listen.owner = nobody/listen.owner = freeswitch/g' /etc/php-fpm.d/www.conf +sed -ie 's/;listen.group = nobody/listen.group = daemon/g' /etc/php-fpm.d/www.conf sed -ie 's/group = apache/group = daemon/g' /etc/php-fpm.d/www.conf #update the php.ini