From d07fe389fa851689d187eeb96cca0883e9617fef Mon Sep 17 00:00:00 2001 From: wn_ Date: Wed, 10 May 2023 01:43:08 +0000 Subject: [PATCH] Bump to Alpine 3.18, PHP 8.2 --- app/Dockerfile | 20 ++++++++++---------- app/startup.sh | 28 ++++++++++++++-------------- app/updater.sh | 4 ++-- 3 files changed, 26 insertions(+), 26 deletions(-) diff --git a/app/Dockerfile b/app/Dockerfile index eccd815..53ae959 100644 --- a/app/Dockerfile +++ b/app/Dockerfile @@ -1,21 +1,21 @@ -FROM alpine:3.17 +FROM alpine:3.18 EXPOSE 9000/tcp ENV SCRIPT_ROOT=/opt/tt-rss -RUN apk add --no-cache dcron php81 php81-fpm php81-phar php81-sockets php81-pecl-apcu \ - php81-pdo php81-gd php81-pgsql php81-pdo_pgsql php81-xmlwriter php81-opcache \ - php81-mbstring php81-intl php81-xml php81-curl php81-simplexml \ - php81-session php81-tokenizer php81-dom php81-fileinfo php81-ctype \ - php81-json php81-iconv php81-pcntl php81-posix php81-zip php81-exif \ - php81-openssl git postgresql-client sudo php81-pecl-xdebug rsync tzdata && \ - sed -i 's/\(memory_limit =\) 128M/\1 256M/' /etc/php81/php.ini && \ +RUN apk add --no-cache dcron php82 php82-fpm php82-phar php82-sockets php82-pecl-apcu \ + php82-pdo php82-gd php82-pgsql php82-pdo_pgsql php82-xmlwriter php82-opcache \ + php82-mbstring php82-intl php82-xml php82-curl php82-simplexml \ + php82-session php82-tokenizer php82-dom php82-fileinfo php82-ctype \ + php82-json php82-iconv php82-pcntl php82-posix php82-zip php82-exif \ + php82-openssl git postgresql-client sudo php82-pecl-xdebug rsync tzdata && \ + sed -i 's/\(memory_limit =\) 128M/\1 256M/' /etc/php82/php.ini && \ sed -i -e 's/^listen = 127.0.0.1:9000/listen = 9000/' \ -e 's/;\(clear_env\) = .*/\1 = no/i' \ -e 's/^\(user\|group\) = .*/\1 = app/i' \ -e 's/;\(php_admin_value\[error_log\]\) = .*/\1 = \/tmp\/error.log/' \ -e 's/;\(php_admin_flag\[log_errors\]\) = .*/\1 = on/' \ - /etc/php81/php-fpm.d/www.conf && \ + /etc/php82/php-fpm.d/www.conf && \ mkdir -p /var/www ${SCRIPT_ROOT}/config.d ADD startup.sh ${SCRIPT_ROOT} @@ -61,7 +61,7 @@ ENV TTRSS_DB_HOST="db" ENV TTRSS_DB_PORT="5432" ENV TTRSS_MYSQL_CHARSET="UTF8" -ENV TTRSS_PHP_EXECUTABLE="/usr/bin/php81" +ENV TTRSS_PHP_EXECUTABLE="/usr/bin/php82" ENV TTRSS_PLUGINS="auth_internal, note, nginx_xaccel" CMD ${SCRIPT_ROOT}/startup.sh diff --git a/app/startup.sh b/app/startup.sh index 560cc40..e725972 100755 --- a/app/startup.sh +++ b/app/startup.sh @@ -90,7 +90,7 @@ for d in cache lock feed-icons; do done chown -R $OWNER_UID:$OWNER_GID $DST_DIR \ - /var/log/php81 + /var/log/php82 $PSQL -c "create extension if not exists pg_trgm" @@ -109,13 +109,13 @@ if [ ! -z "${TTRSS_CORE_DUMPS_ENABLED}" ]; then echo "don't forget to enable core dumps on the host:" echo "echo '/tmp/core-%e.%p' > /proc/sys/kernel/core_pattern" - echo "then run gdb /usr/sbin/php-fpm81 /tmp/coredump-php-fpm-xyz" + echo "then run gdb /usr/sbin/php-fpm82 /tmp/coredump-php-fpm-xyz" # enable core dumps sed -i.bak \ -e 's/;\(rlimit_core\) = .*/\1 = unlimited/' \ -e 's/; *\(process.dumpable\) = .*/\1 = yes/' \ - /etc/php81/php-fpm.d/www.conf + /etc/php82/php-fpm.d/www.conf fi if [ ! -z "${TTRSS_XDEBUG_ENABLED}" ]; then @@ -124,7 +124,7 @@ if [ ! -z "${TTRSS_XDEBUG_ENABLED}" ]; then fi echo enabling xdebug with the following parameters: env | grep TTRSS_XDEBUG - cat > /etc/php81/conf.d/50_xdebug.ini < /etc/php82/conf.d/50_xdebug.ini <