php7-fpm error no ACL enabled, so unable to start php fpm services in any form
This is a problem in alpine 3.10, 3.11, 3.12, 3.13 and edge also:
fpm fails to start due usage of "listen.acl_groups
" or/and
"listen.acl_users
" ACL feature, available since php 5.6
Solution:
FPM needs to be compiled with --with-fpm-acl
(depends on acl-dev) for listen.acl_users
directive to work.
How to reproduce:
sed -i -r 's|^pid =.*|pid = /run/php-fpm7/php7-fpm.pid|g' /etc/php*/php-fpm.conf
sed -i -r 's#^user =.*#user = root#g' /etc/php*/php-fpm.d/www.conf
sed -i -r 's#^group =.*#group = www-data#g' /etc/php*/php-fpm.d/www.conf
sed -i -r 's|^.*listen =.*|listen = /run/php-fpm7/php7-fpm.sock|g' /etc/php*/php-fpm.d/www.conf
sed -i -r 's|^.*listen.acl_users =.*|listen.acl_users = daemon,lighttpd|g' /etc/php*/php-fpm.d/www.conf
sed -i -r 's|^.*listen.acl_groups =.*|listen.acl_groups = lighttpd,www-data|g' /etc/php*/php-fpm.d/www.conf
sed -i -r 's|^.*listen.mode =.*|listen.mode = 0660|g' /etc/php*/php-fpm.d/www.conf
service php-fpm7 restart
actual results:
* Stopping PHP FastCGI Process Manager ... [ ok ]
* Checking /etc/php7/php-fpm.conf ...
[09-Jun-2021 14:55:53] ERROR: [/etc/php7/php-fpm.d/www.conf:53] unknown entry 'listen.acl_users'
[09-Jun-2021 14:55:53] ERROR: Unable to include /etc/php7/php-fpm.d/www.conf from /etc/php7/php-fpm.conf at line 53
[09-Jun-2021 14:55:53] ERROR: failed to load configuration file '/etc/php7/php-fpm.conf'
[09-Jun-2021 14:55:53] ERROR: FPM initialization failed
* failed, please correct errors above [ !! ]
* ERROR: php-fpm7 failed to start
Alpine since ancient packagin never enabled important features i suspect that has same problems of the debian packages cos i found SAME problems as on debian.