From 229034ba24143c48e1e2aa338326ce904b21cb3c Mon Sep 17 00:00:00 2001 From: stickz Date: Mon, 23 Dec 2024 16:23:22 -0500 Subject: [PATCH] Upgrade to Alpine 3.20 & PHP 8.3 This pull request upgrades to Alpine 3.20 and PHP 8.3. I intend to go to Alpine 3.21 for GCC 14 once the crazy-max S6 image supports it. This preparation step is required and the new PHP version is also beneficial. --- Dockerfile | 42 +++++++++---------- rootfs/etc/cont-init.d/02-fix-perms.sh | 2 +- rootfs/etc/cont-init.d/03-config.sh | 10 ++--- rootfs/etc/cont-init.d/04-create-services.sh | 2 +- .../etc/{php82 => php83}/conf.d/opcache.ini | 0 .../etc/{php82 => php83}/php-fpm.d/www.conf | 0 rootfs/tpls/etc/rtorrent/.rtlocal.rc | 2 +- 7 files changed, 29 insertions(+), 29 deletions(-) rename rootfs/tpls/etc/{php82 => php83}/conf.d/opcache.ini (100%) rename rootfs/tpls/etc/{php82 => php83}/php-fpm.d/www.conf (100%) diff --git a/Dockerfile b/Dockerfile index 3ede60c2..2d5981cc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,7 +15,7 @@ ARG DUMP_TORRENT_VERSION=302ac444a20442edb4aeabef65b264a85ab88ce9 # v6.2-0.9.8-0.13.8 ARG RTORRENT_STICKZ_VERSION=0165b4b6dde384d30c2b41ae6d6a2cd23b55c71e -ARG ALPINE_VERSION=3.19 +ARG ALPINE_VERSION=3.20 ARG ALPINE_S6_VERSION=${ALPINE_VERSION}-2.2.0.3 FROM --platform=${BUILDPLATFORM} alpine:${ALPINE_VERSION} AS src @@ -95,8 +95,8 @@ RUN apk --update --no-cache add \ nghttp2-dev \ openssl-dev \ pcre-dev \ - php82-dev \ - php82-pear \ + php83-dev \ + php83-pear \ tar \ tree \ udns-dev \ @@ -171,13 +171,13 @@ WORKDIR /usr/local/src/geoip2-phpext COPY --from=src-geoip2-phpext /src . RUN < /etc/php82/php-fpm.d/www.conf + /tpls/etc/php83/php-fpm.d/www.conf > /etc/php83/php-fpm.d/www.conf echo "Setting PHP INI configuration..." -sed -i "s|memory_limit.*|memory_limit = ${MEMORY_LIMIT}|g" /etc/php82/php.ini -sed -i "s|;date\.timezone.*|date\.timezone = ${TZ}|g" /etc/php82/php.ini -sed -i "s|max_file_uploads.*|max_file_uploads = ${MAX_FILE_UPLOADS}|g" /etc/php82/php.ini +sed -i "s|memory_limit.*|memory_limit = ${MEMORY_LIMIT}|g" /etc/php83/php.ini +sed -i "s|;date\.timezone.*|date\.timezone = ${TZ}|g" /etc/php83/php.ini +sed -i "s|max_file_uploads.*|max_file_uploads = ${MAX_FILE_UPLOADS}|g" /etc/php83/php.ini # OpCache echo "Setting OpCache configuration..." sed -e "s/@OPCACHE_MEM_SIZE@/$OPCACHE_MEM_SIZE/g" \ - /tpls/etc/php82/conf.d/opcache.ini > /etc/php82/conf.d/opcache.ini + /tpls/etc/php83/conf.d/opcache.ini > /etc/php83/conf.d/opcache.ini # Nginx echo "Setting Nginx configuration..." diff --git a/rootfs/etc/cont-init.d/04-create-services.sh b/rootfs/etc/cont-init.d/04-create-services.sh index f00c3e0c..43af81ce 100644 --- a/rootfs/etc/cont-init.d/04-create-services.sh +++ b/rootfs/etc/cont-init.d/04-create-services.sh @@ -15,7 +15,7 @@ cat > /etc/services.d/php-fpm/run <