Php-fpm и apache после изменения пользователя, запрос на доступ не имеет разрешения ⇐ Apache
-
Гость
Php-fpm и apache после изменения пользователя, запрос на доступ не имеет разрешения
When I change the startup user for Apache and php-fpm, I get error 503 index.php access and Apache error
OS:Amazon linux 2023 Selinux: Enforcing Apache version:2.48 php version:8.2 change to user:apps groups:appsgrp
Folder:/var/local/app Owner:apps:appsgrp
/etc/httpf/conf/httpd.conf
ServerRoot "/etc/httpd" Listen 8443 Include conf.modules.d/*.conf User apps Group appsgrp ServerAdmin root@localhost AllowOverride none Require all denied DocumentRoot "/var/local/app/httpd/html" AllowOverride None Require all granted Options Indexes FollowSymLinks AllowOverride None Require all granted DirectoryIndex index.html Require all denied ErrorLog "logs/error_log" LogLevel warn LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio CustomLog "logs/access_log" combined ScriptAlias /cgi-bin/ "/var/local/app/httpd/cgi-bin/" AllowOverride None Options None Require all granted TypesConfig /etc/mime.types AddType application/x-compress .Z AddType application/x-gzip .gz .tgz AddType text/html .shtml AddOutputFilter INCLUDES .shtml AddDefaultCharset UTF-8 MIMEMagicFile conf/magic EnableSendfile on IncludeOptional conf.d/*.conf I just changed the user and group fields in this file.
/etc/php-fpm.d/conf/www.conf
user apps group appsgrp error info
enter image description here
I've tried to set the permissions of a lot of directories, but they still get errors, so I don't know where the problem is?
Источник: https://stackoverflow.com/questions/781 ... not-have-p
When I change the startup user for Apache and php-fpm, I get error 503 index.php access and Apache error
OS:Amazon linux 2023 Selinux: Enforcing Apache version:2.48 php version:8.2 change to user:apps groups:appsgrp
Folder:/var/local/app Owner:apps:appsgrp
/etc/httpf/conf/httpd.conf
ServerRoot "/etc/httpd" Listen 8443 Include conf.modules.d/*.conf User apps Group appsgrp ServerAdmin root@localhost AllowOverride none Require all denied DocumentRoot "/var/local/app/httpd/html" AllowOverride None Require all granted Options Indexes FollowSymLinks AllowOverride None Require all granted DirectoryIndex index.html Require all denied ErrorLog "logs/error_log" LogLevel warn LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio CustomLog "logs/access_log" combined ScriptAlias /cgi-bin/ "/var/local/app/httpd/cgi-bin/" AllowOverride None Options None Require all granted TypesConfig /etc/mime.types AddType application/x-compress .Z AddType application/x-gzip .gz .tgz AddType text/html .shtml AddOutputFilter INCLUDES .shtml AddDefaultCharset UTF-8 MIMEMagicFile conf/magic EnableSendfile on IncludeOptional conf.d/*.conf I just changed the user and group fields in this file.
/etc/php-fpm.d/conf/www.conf
user apps group appsgrp error info
enter image description here
I've tried to set the permissions of a lot of directories, but they still get errors, so I don't know where the problem is?
Источник: https://stackoverflow.com/questions/781 ... not-have-p
Мобильная версия