From 6a283f15b950ff5880770b6eda957462ee0d4c96 Mon Sep 17 00:00:00 2001 From: ale <ale@incal.net> Date: Sun, 31 Oct 2021 13:21:59 +0000 Subject: [PATCH] Build with S6 (bullseye) --- Dockerfile | 3 +-- docker/conf/chaperone.d/clean-sessions.service | 5 ----- docker/conf/chaperone.d/startup.conf | 8 -------- .../cont-init.d/99noblogs-post-upgrade} | 2 +- docker/conf/php/{7.3 => 7.4}/fpm/conf.d/99-noblogs.ini | 0 docker/conf/php/{7.3 => 7.4}/fpm/pool.d/www.conf | 2 +- 6 files changed, 3 insertions(+), 17 deletions(-) delete mode 100644 docker/conf/chaperone.d/clean-sessions.service delete mode 100644 docker/conf/chaperone.d/startup.conf rename docker/{post-upgrade.sh => conf/cont-init.d/99noblogs-post-upgrade} (99%) rename docker/conf/php/{7.3 => 7.4}/fpm/conf.d/99-noblogs.ini (100%) rename docker/conf/php/{7.3 => 7.4}/fpm/pool.d/www.conf (95%) diff --git a/Dockerfile b/Dockerfile index 1866a564..9c65de39 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ ADD . /build WORKDIR /build RUN /build/install.sh -FROM registry.git.autistici.org/ai3/docker/apache2-php-base:master +FROM registry.git.autistici.org/ai3/docker/apache2-php-base:s6 COPY --from=build /build/app/ /opt/noblogs/www @@ -13,7 +13,6 @@ COPY docker/wp-config.php /opt/noblogs/www/wp-config.php COPY docker/wp-cache-config.php /opt/noblogs/www/wp-content/wp-cache-config.php COPY docker/conf /tmp/conf COPY docker/build.sh /tmp/build.sh -COPY docker/post-upgrade.sh /post-upgrade.sh RUN /tmp/build.sh && rm /tmp/build.sh diff --git a/docker/conf/chaperone.d/clean-sessions.service b/docker/conf/chaperone.d/clean-sessions.service deleted file mode 100644 index ab03897f..00000000 --- a/docker/conf/chaperone.d/clean-sessions.service +++ /dev/null @@ -1,5 +0,0 @@ -clean_sessions.service: { - type: cron, - interval: "10,40 * * * *", - command: "/usr/bin/find /var/lib/php/sessions -mindepth 1 -type f -mtime +1 -delete", -} diff --git a/docker/conf/chaperone.d/startup.conf b/docker/conf/chaperone.d/startup.conf deleted file mode 100644 index 847ae6a9..00000000 --- a/docker/conf/chaperone.d/startup.conf +++ /dev/null @@ -1,8 +0,0 @@ -noblogs_upgrade.service: { - type: oneshot, - stdout: inherit, - command: "/post-upgrade.sh", - ignore_failures: true, - process_timeout: 7200, - exit_kills: false, -} diff --git a/docker/post-upgrade.sh b/docker/conf/cont-init.d/99noblogs-post-upgrade similarity index 99% rename from docker/post-upgrade.sh rename to docker/conf/cont-init.d/99noblogs-post-upgrade index a2d017af..731f7954 100755 --- a/docker/post-upgrade.sh +++ b/docker/conf/cont-init.d/99noblogs-post-upgrade @@ -44,4 +44,4 @@ if [ $cur_schema_version -lt $new_schema_version ]; then echo "network upgrade message removed" fi -exit 0 \ No newline at end of file +exit 0 diff --git a/docker/conf/php/7.3/fpm/conf.d/99-noblogs.ini b/docker/conf/php/7.4/fpm/conf.d/99-noblogs.ini similarity index 100% rename from docker/conf/php/7.3/fpm/conf.d/99-noblogs.ini rename to docker/conf/php/7.4/fpm/conf.d/99-noblogs.ini diff --git a/docker/conf/php/7.3/fpm/pool.d/www.conf b/docker/conf/php/7.4/fpm/pool.d/www.conf similarity index 95% rename from docker/conf/php/7.3/fpm/pool.d/www.conf rename to docker/conf/php/7.4/fpm/pool.d/www.conf index 9be0c609..29410023 100644 --- a/docker/conf/php/7.3/fpm/pool.d/www.conf +++ b/docker/conf/php/7.4/fpm/pool.d/www.conf @@ -1,6 +1,6 @@ [www] user = ${PHP_FPM_USER} -listen = /run/php/php7.3-fpm.sock +listen = /run/php/php7.4-fpm.sock pm = dynamic pm.max_children = 75 -- GitLab