From 2cff95b01171e319631c2ffb801bf23d8c43e229 Mon Sep 17 00:00:00 2001 From: Tommy Date: Fri, 26 Jul 2024 08:09:25 -0700 Subject: [PATCH] Fix PHP permissions --- sample-scripts/RHEL-9-LEMP.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sample-scripts/RHEL-9-LEMP.sh b/sample-scripts/RHEL-9-LEMP.sh index 855ddaf..4600f81 100644 --- a/sample-scripts/RHEL-9-LEMP.sh +++ b/sample-scripts/RHEL-9-LEMP.sh @@ -50,3 +50,9 @@ sudo dnf install -y MariaDB-server # Run NGINX Setup script unpriv curl -LsS https://raw.githubusercontent.com/TommyTran732/NGINX-Configs/main/setup.sh | sudo bash + +# Fix PHP permission +sudo sed -i 's/user = apache/user = nginx/g' /etc/php-fpm.d/www.conf +sudo sed -i 's/group = apache/group = nginx/g' /etc/php-fpm.d/www.conf +chgrp nginx /var/lib/php/opcache /var/lib/php/session /var/lib/php/wsdlcache +sudo systemctl restart php-fpm \ No newline at end of file