From b3fffb877e66d3f215108aac5700ca87ee454937 Mon Sep 17 00:00:00 2001 From: Simon L Date: Thu, 21 Sep 2023 15:38:23 +0200 Subject: [PATCH] Revert "Mastercontainer - use php unix socket" --- Containers/mastercontainer/Dockerfile | 6 ++---- Containers/mastercontainer/healthcheck.sh | 2 +- Containers/mastercontainer/mastercontainer.conf | 2 +- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/Containers/mastercontainer/Dockerfile b/Containers/mastercontainer/Dockerfile index 3df0f3cb..efef5a6f 100644 --- a/Containers/mastercontainer/Dockerfile +++ b/Containers/mastercontainer/Dockerfile @@ -56,10 +56,8 @@ RUN set -ex; \ sed -i 's/^pm = dynamic/pm = ondemand/' /usr/local/etc/php-fpm.d/www.conf; \ sed -i 's/^pm.max_children =.*/pm.max_children = 80/' /usr/local/etc/php-fpm.d/www.conf; \ sed -i 's|access.log = /proc/self/fd/2|access.log = /proc/self/fd/1|' /usr/local/etc/php-fpm.d/docker.conf; \ - grep -q 'listen =' /usr/local/etc/php-fpm.d/www.conf; \ - sed -i 's|listen =.*|;listen = /var/run/php.sock # handled in zz-docker.conf|' /usr/local/etc/php-fpm.d/www.conf; \ - grep -q 'listen =' /usr/local/etc/php-fpm.d/zz-docker.conf; \ - sed -i 's|listen =.*|listen = /var/run/php.sock|' /usr/local/etc/php-fpm.d/zz-docker.conf; \ + grep -q ';listen.allowed_clients' /usr/local/etc/php-fpm.d/www.conf; \ + sed -i 's|;listen.allowed_clients.*|listen.allowed_clients = 127.0.0.1,::1|' /usr/local/etc/php-fpm.d/www.conf; \ \ apk add --no-cache git; \ wget https://getcomposer.org/installer -O - | php -- --install-dir=/usr/local/bin --filename=composer; \ diff --git a/Containers/mastercontainer/healthcheck.sh b/Containers/mastercontainer/healthcheck.sh index ef2931a8..e5d27771 100644 --- a/Containers/mastercontainer/healthcheck.sh +++ b/Containers/mastercontainer/healthcheck.sh @@ -5,6 +5,6 @@ if [ -f "/mnt/docker-aio-config/data/configuration.json" ]; then nc -z localhost 8000 || exit 1 nc -z localhost 8080 || exit 1 nc -z localhost 8443 || exit 1 + nc -z localhost 9000 || exit 1 nc -z localhost 9876 || exit 1 - [ -f /var/run/php.sock ] || exit 1 fi diff --git a/Containers/mastercontainer/mastercontainer.conf b/Containers/mastercontainer/mastercontainer.conf index e3f6943b..701cb420 100644 --- a/Containers/mastercontainer/mastercontainer.conf +++ b/Containers/mastercontainer/mastercontainer.conf @@ -19,7 +19,7 @@ Listen 8080 # PHP match - SetHandler "proxy:unix:/var/run/php.sock" + SetHandler "proxy:fcgi://localhost:9000" # Master dir DocumentRoot /var/www/docker-aio/php/public/