From 7d141bb3b2b35fdfe55e3d4fbf8e3c5701bf983e Mon Sep 17 00:00:00 2001 From: Julien Cabillot Date: Sun, 5 Jan 2025 10:17:04 -0500 Subject: [PATCH] feat: move to php83 --- Dockerfile | 18 +++++++++--------- root/etc/cont-init.d/50-php | 4 ++-- root/etc/cont-init.d/98-wait-for-db | 0 root/etc/cont-init.d/99-ttrss | 0 root/etc/nginx/nginx.conf | 3 +-- root/etc/{php7 => php83}/php-fpm.conf | 0 root/etc/services.d/nginx/run | 0 root/etc/services.d/php/run | 0 root/etc/services.d/ttrss-daemon/run | 0 root/etc/services.d/ttrss-updater/run | 0 root/srv/update-ttrss.sh | 2 +- 11 files changed, 13 insertions(+), 14 deletions(-) mode change 100644 => 100755 root/etc/cont-init.d/50-php mode change 100644 => 100755 root/etc/cont-init.d/98-wait-for-db mode change 100644 => 100755 root/etc/cont-init.d/99-ttrss rename root/etc/{php7 => php83}/php-fpm.conf (100%) mode change 100644 => 100755 root/etc/services.d/nginx/run mode change 100644 => 100755 root/etc/services.d/php/run mode change 100644 => 100755 root/etc/services.d/ttrss-daemon/run mode change 100644 => 100755 root/etc/services.d/ttrss-updater/run diff --git a/Dockerfile b/Dockerfile index 309e478..cdc9af2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # Using https://github.com/gliderlabs/docker-alpine, # plus https://github.com/just-containers/s6-overlay for a s6 Docker overlay. -FROM alpine:3.14 +FROM alpine:3.21 # Initially was based on work of Christian Lück . LABEL description="A complete, self-hosted Tiny Tiny RSS (TTRSS) environment." \ maintainer="Andreas Löffler " @@ -10,10 +10,10 @@ RUN set -xe && \ apk add --no-cache --virtual=run-deps \ s6 s6-linux-init s6-overlay \ busybox nginx git ca-certificates curl \ - php7 php7-fpm php7-curl php7-dom php7-gd php7-iconv php7-fileinfo php7-json \ - php7-mcrypt php7-pgsql php7-pcntl php7-pdo php7-pdo_pgsql \ - php7-mysqli php7-pdo_mysql \ - php7-mbstring php7-posix php7-session php7-intl + php83 php83-fpm php83-curl php83-dom php83-gd php83-iconv php83-fileinfo php83-json \ + php83-pecl-mcrypt php83-pgsql php83-pcntl php83-pdo php83-pdo_pgsql \ + php83-mysqli php83-pdo_mysql \ + php83-mbstring php83-posix php83-session php83-intl # Add user www-data for php-fpm. # 82 is the standard uid/gid for "www-data" in Alpine. @@ -24,7 +24,7 @@ COPY root / # Add s6 overlay. # Note: Tweak this line if you're running anything other than x86 AMD64 (64-bit). -RUN curl -L -s https://github.com/just-containers/s6-overlay/releases/download/v3.1.3.0/s6-overlay-x86_64.tar.xz -o s6-overlay-x86_64.tar.xz && \ +RUN curl --connect-timeout 30 -L -s https://github.com/just-containers/s6-overlay/releases/download/v3.1.3.0/s6-overlay-x86_64.tar.xz -o s6-overlay-x86_64.tar.xz && \ tar xvf s6-overlay-x86_64.tar.xz -C / && \ rm s6-overlay-x86_64.tar.xz @@ -37,9 +37,9 @@ EXPOSE 8080 EXPOSE 4443 # Expose default database credentials via ENV in order to ease overwriting. -ENV DB_NAME ttrss -ENV DB_USER ttrss -ENV DB_PASS ttrss +ENV DB_NAME=ttrss +ENV DB_USER=ttrss +ENV DB_PASS=ttrss # Clean up. RUN set -xe && apk del --progress --purge && rm -rf /var/cache/apk/* && rm -rf /var/lib/apt/lists/* diff --git a/root/etc/cont-init.d/50-php b/root/etc/cont-init.d/50-php old mode 100644 new mode 100755 index 6ce72c5..d433d71 --- a/root/etc/cont-init.d/50-php +++ b/root/etc/cont-init.d/50-php @@ -4,7 +4,7 @@ # regardless of how the package maintainer(s) named those. rm -f /usr/bin/php -ln -s /usr/bin/php7 /usr/bin/php +ln -s /usr/bin/php83 /usr/bin/php rm -f /usr/sbin/php-fpm -ln -s /usr/sbin/php-fpm7 /usr/sbin/php-fpm +ln -s /usr/sbin/php-fpm83 /usr/sbin/php-fpm diff --git a/root/etc/cont-init.d/98-wait-for-db b/root/etc/cont-init.d/98-wait-for-db old mode 100644 new mode 100755 diff --git a/root/etc/cont-init.d/99-ttrss b/root/etc/cont-init.d/99-ttrss old mode 100644 new mode 100755 diff --git a/root/etc/nginx/nginx.conf b/root/etc/nginx/nginx.conf index eb42325..4d6d274 100644 --- a/root/etc/nginx/nginx.conf +++ b/root/etc/nginx/nginx.conf @@ -33,10 +33,9 @@ http { server { - listen 4443; + listen 4443 ssl; root /var/www/ttrss; - ssl on; ssl_certificate /etc/ssl/certs/ttrss.crt; ssl_certificate_key /etc/ssl/private/ttrss.key; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; diff --git a/root/etc/php7/php-fpm.conf b/root/etc/php83/php-fpm.conf similarity index 100% rename from root/etc/php7/php-fpm.conf rename to root/etc/php83/php-fpm.conf diff --git a/root/etc/services.d/nginx/run b/root/etc/services.d/nginx/run old mode 100644 new mode 100755 diff --git a/root/etc/services.d/php/run b/root/etc/services.d/php/run old mode 100644 new mode 100755 diff --git a/root/etc/services.d/ttrss-daemon/run b/root/etc/services.d/ttrss-daemon/run old mode 100644 new mode 100755 diff --git a/root/etc/services.d/ttrss-updater/run b/root/etc/services.d/ttrss-updater/run old mode 100644 new mode 100755 diff --git a/root/srv/update-ttrss.sh b/root/srv/update-ttrss.sh index c13a3b9..961396e 100755 --- a/root/srv/update-ttrss.sh +++ b/root/srv/update-ttrss.sh @@ -60,7 +60,7 @@ update_common() fi echo "Updating: Updating permissions" - for CUR_DIR in /etc/nginx /etc/php7 /var/lib/nginx /etc/services.d; do + for CUR_DIR in /etc/nginx /etc/php83 /var/lib/nginx /etc/services.d; do chown -R ${MY_ROOT_UID}:${MY_ROOT_GID} ${CUR_DIR} done