From 49cc37c57ff15c6552d400bc97dcb6a5a1ff8b4e Mon Sep 17 00:00:00 2001 From: Michael Aguiar Date: Wed, 21 Oct 2026 15:43:31 -0700 Subject: [PATCH 1/2] Drop the end-of-life 7.4, 8.0 and 8.1 CLI images PHP 8.1 and older are past end of life and the images sit on EOL Alpine branches, so rebuilding them changes nothing and they carry none of the PHP security fixes since. Nothing in use pulls them, and the plain 7.4/8.0/8.1-cli tags were already pruned from the registry on 2026-10-15. Remove their Dockerfiles, their change-detection entries, matrix rows, force-build inputs and summary lines, and the eol matrix flag that only they used. The published -latest tags stay in the registry, unmaintained. --- .github/workflows/build-and-push.yml | 36 ++++------------------------ README.md | 9 +++---- php/7.4/cli/Dockerfile | 35 --------------------------- php/8.0/cli/Dockerfile | 35 --------------------------- php/8.1/cli/Dockerfile | 35 --------------------------- 5 files changed, 8 insertions(+), 142 deletions(-) delete mode 100644 php/7.4/cli/Dockerfile delete mode 100644 php/8.0/cli/Dockerfile delete mode 100644 php/8.1/cli/Dockerfile diff --git a/.github/workflows/build-and-push.yml b/.github/workflows/build-and-push.yml index 46683fd..98bee68 100644 --- a/.github/workflows/build-and-push.yml +++ b/.github/workflows/build-and-push.yml @@ -6,10 +6,10 @@ on: # Weekly rebuild, so updates to the base images (new php.net patch # releases in the official php images; rebuilds of the pinned # dunglas/frankenphp version) and Alpine package fixes reach the tags - # without a Dockerfile change. Scheduled runs build everything except the - # EOL cli images (each build condition checks github.event_name) and skip - # the layer cache (no-cache on each build step). A new FrankenPHP release - # still needs FRANKENPHP_VERSION bumped by hand. + # without a Dockerfile change. Scheduled runs build everything (each + # build condition checks github.event_name) and skip the layer cache + # (no-cache on each build step). A new FrankenPHP release still needs + # FRANKENPHP_VERSION bumped by hand. schedule: - cron: "0 10 * * 1" # Mondays 10:00 UTC workflow_dispatch: @@ -19,21 +19,6 @@ on: required: false default: false type: boolean - build_php_74: - description: "Force build PHP 7.4 images" - required: false - default: false - type: boolean - build_php_80: - description: "Force build PHP 8.0 images" - required: false - default: false - type: boolean - build_php_81: - description: "Force build PHP 8.1 images" - required: false - default: false - type: boolean build_php_82: description: "Force build PHP 8.2 images" required: false @@ -82,9 +67,6 @@ jobs: uses: tj-actions/changed-files@v47 with: files: | - php/7.4/cli/Dockerfile - php/8.0/cli/Dockerfile - php/8.1/cli/Dockerfile php/8.2/frankenphp/Dockerfile php/8.2/frankenphp/Dockerfile.dev php/8.2/frankenphp/Dockerfile.wordpress @@ -125,9 +107,6 @@ jobs: fail-fast: false matrix: include: - - { name: 7.4-cli, context: php/7.4/cli, file: php/7.4/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_74, tag: 7.4-cli, eol: true } - - { name: 8.0-cli, context: php/8.0/cli, file: php/8.0/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_80, tag: 8.0-cli, eol: true } - - { name: 8.1-cli, context: php/8.1/cli, file: php/8.1/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_81, tag: 8.1-cli, eol: true } - { name: 8.3-cli, context: php/8.3/cli, file: php/8.3/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_83, tag: 8.3-cli } - { name: 8.4-cli, context: php/8.4/cli, file: php/8.4/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_84, tag: 8.4-cli } - { name: 8.5-cli, context: php/8.5/cli, file: php/8.5/cli/Dockerfile, platforms: "linux/amd64,linux/arm64", force_input: build_php_85, tag: 8.5-cli } @@ -150,9 +129,7 @@ jobs: password: ${{ secrets.GITHUB_TOKEN }} - name: Build and push ${{ matrix.name }} - # EOL images (eol: true) skip the weekly rebuild: their Alpine branches get - # no updates, so it would only re-push identical images. - if: ${{ inputs.force_build_all || (github.event_name == 'schedule' && !matrix.eol) || inputs[matrix.force_input] || contains(needs.detect-changes.outputs.changed_files, matrix.file) }} + if: ${{ inputs.force_build_all || github.event_name == 'schedule' || inputs[matrix.force_input] || contains(needs.detect-changes.outputs.changed_files, matrix.file) }} uses: docker/build-push-action@v7 with: context: ${{ matrix.context }} @@ -610,9 +587,6 @@ jobs: echo "**Registry:** \`ghcr.io/${{ github.repository }}\`" >> $GITHUB_STEP_SUMMARY echo "" >> $GITHUB_STEP_SUMMARY echo "**Available Images:**" >> $GITHUB_STEP_SUMMARY - echo "- **PHP 7.4:** \`7.4-cli-latest\`" >> $GITHUB_STEP_SUMMARY - echo "- **PHP 8.0:** \`8.0-cli-latest\`" >> $GITHUB_STEP_SUMMARY - echo "- **PHP 8.1:** \`8.1-cli-latest\`" >> $GITHUB_STEP_SUMMARY echo "- **PHP 8.2:** \`8.2-frankenphp-latest\`, \`8.2-frankenphp-dev-latest\`, \`8.2-frankenphp-wordpress-latest\`" >> $GITHUB_STEP_SUMMARY echo "- **PHP 8.3:** \`8.3-cli-latest\`, \`8.3-frankenphp-latest\`, \`8.3-frankenphp-dev-latest\`, \`8.3-frankenphp-wordpress-latest\`" >> $GITHUB_STEP_SUMMARY echo "- **PHP 8.4:** \`8.4-cli-latest\`, \`8.4-frankenphp-latest\`, \`8.4-frankenphp-dev-latest\`, \`8.4-frankenphp-wordpress-latest\`" >> $GITHUB_STEP_SUMMARY diff --git a/README.md b/README.md index 458f7a6..43869b6 100644 --- a/README.md +++ b/README.md @@ -1,20 +1,17 @@ # docker-php -Docker images for PHP, published to `ghcr.io/aliasproject/php`. The primary offering is [FrankenPHP](https://frankenphp.dev/) (Caddy + PHP) for 8.2–8.5, plus CLI images for 7.4–8.1 and 8.3–8.5. +Docker images for PHP, published to `ghcr.io/aliasproject/php`. The primary offering is [FrankenPHP](https://frankenphp.dev/) (Caddy + PHP) for 8.2–8.5, plus CLI images for 8.3–8.5. Images for PHP versions past end of life (8.1 and older) are no longer built; their last `7.4/8.0/8.1-cli-latest` tags are left in the registry but get no updates. ## Image matrix | PHP | CLI | FrankenPHP | FrankenPHP (dev) | FrankenPHP (WordPress) | |------|:---:|:----------:|:-----------------:|:------------------------:| -| 7.4 | ✅ | | | | -| 8.0 | ✅ | | | | -| 8.1 | ✅ | | | | | 8.2 | | ✅ | ✅ | ✅ | | 8.3 | ✅ | ✅ | ✅ | ✅ | | 8.4 | ✅ | ✅ | ✅ | ✅ | | 8.5 | ✅ | ✅ | ✅ | ✅ | -Tags follow `-` (e.g. `8.4-frankenphp-wordpress`), each also published as `-latest` and as `-` for the commit it was built from. Every image except the EOL 7.4–8.1 CLI images is rebuilt weekly (Mondays 10:00 UTC) to pick up base-image and Alpine package updates, which also refreshes the `-` tag of the current commit; pin by digest (`@sha256:…`) for a byte-for-byte fixed image. The frankenphp images stay on their pinned FrankenPHP version, so a new FrankenPHP release (and the PHP version it ships) still needs `FRANKENPHP_VERSION` bumped in their Dockerfiles. +Tags follow `-` (e.g. `8.4-frankenphp-wordpress`), each also published as `-latest` and as `-` for the commit it was built from. Every image is rebuilt weekly (Mondays 10:00 UTC) to pick up base-image and Alpine package updates, which also refreshes the `-` tag of the current commit; pin by digest (`@sha256:…`) for a byte-for-byte fixed image. The frankenphp images stay on their pinned FrankenPHP version, so a new FrankenPHP release (and the PHP version it ships) still needs `FRANKENPHP_VERSION` bumped in their Dockerfiles. ```sh docker pull ghcr.io/aliasproject/php:8.4-frankenphp @@ -22,7 +19,7 @@ docker pull ghcr.io/aliasproject/php:8.4-frankenphp ## Variants -- **cli** — the PHP CLI with unlimited execution time. 8.3–8.5 are built on the official `php:-cli-alpine` images, so a rebuild picks up the latest php.net patch release (7.4–8.1 still use Alpine's EOL packages). 8.3–8.5 are also rebuilt weekly (Mondays 10:00 UTC), so they pick up new PHP patch releases without a Dockerfile change. PHP's ini files are in `/usr/local/etc/php` (`conf.d/` for overrides). 8.3–8.5 are identical apart from the PHP version: a minimal extension set (`pdo_mysql`, `bcmath`, `intl`, `pcntl`, `zip`, etc.), a 512M memory limit, and an unprivileged `appuser` in group `0`. Backend and library extensions (`mysqli`, `gd`, `imagick`, `redis`, `igbinary`, …) belong in a derived image such as `php/8.4/cli/Dockerfile.wordpress`. +- **cli** — the PHP CLI with unlimited execution time. 8.3–8.5 are built on the official `php:-cli-alpine` images, so a rebuild picks up the latest php.net patch release. 8.3–8.5 are also rebuilt weekly (Mondays 10:00 UTC), so they pick up new PHP patch releases without a Dockerfile change. PHP's ini files are in `/usr/local/etc/php` (`conf.d/` for overrides). 8.3–8.5 are identical apart from the PHP version: a minimal extension set (`pdo_mysql`, `bcmath`, `intl`, `pcntl`, `zip`, etc.), a 512M memory limit, and an unprivileged `appuser` in group `0`. Backend and library extensions (`mysqli`, `gd`, `imagick`, `redis`, `igbinary`, …) belong in a derived image such as `php/8.4/cli/Dockerfile.wordpress`. - **frankenphp** — FrankenPHP serves PHP directly through Caddy; no separate web server. Minimal extension set, non-root by default, mail sent through `msmtp`, Composer baked in, `HEALTHCHECK` against Caddy's admin API. - **frankenphp (dev)** — the FrankenPHP base with extra extensions (`mysqli`, `gd`, `exif`, `imagick`, `redis`, `igbinary`, `soap`) for local development. - **frankenphp (wordpress)** — the FrankenPHP base with the same extensions as `dev`, plus a hardening policy suited to running WordPress (see below). diff --git a/php/7.4/cli/Dockerfile b/php/7.4/cli/Dockerfile deleted file mode 100644 index 58286b5..0000000 --- a/php/7.4/cli/Dockerfile +++ /dev/null @@ -1,35 +0,0 @@ -FROM alpine:3.15.0 - -LABEL maintainer="Michael Aguiar " - -RUN apk add --no-cache \ - curl \ - php7 \ - php7-bcmath \ - php7-common \ - php7-ctype \ - php7-curl \ - php7-dom \ - php7-exif \ - php7-fileinfo \ - php7-gd \ - php7-iconv \ - php7-json \ - php7-mbstring \ - php7-mysqli \ - php7-opcache \ - php7-openssl \ - php7-pdo_mysql \ - php7-pecl-imagick \ - php7-phar \ - php7-session \ - php7-simplexml \ - php7-tokenizer \ - php7-xml \ - php7-xmlreader \ - php7-xmlwriter \ - php7-zip - -WORKDIR /app - -CMD ["php", "-a"] diff --git a/php/8.0/cli/Dockerfile b/php/8.0/cli/Dockerfile deleted file mode 100644 index 34e2f01..0000000 --- a/php/8.0/cli/Dockerfile +++ /dev/null @@ -1,35 +0,0 @@ -FROM alpine:3.15.0 - -LABEL maintainer="Michael Aguiar " - -RUN apk add --no-cache \ - curl \ - php8 \ - php8-bcmath \ - php8-common \ - php8-ctype \ - php8-curl \ - php8-dom \ - php8-exif \ - php8-fileinfo \ - php8-gd \ - php8-iconv \ - php8-mbstring \ - php8-mysqli \ - php8-opcache \ - php8-openssl \ - php8-pdo_mysql \ - php8-pecl-imagick \ - php8-phar \ - php8-session \ - php8-simplexml \ - php8-tokenizer \ - php8-xml \ - php8-xmlreader \ - php8-xmlwriter \ - php8-zip && \ - ln -s /usr/bin/php8 /usr/bin/php - -WORKDIR /app - -CMD ["php", "-a"] diff --git a/php/8.1/cli/Dockerfile b/php/8.1/cli/Dockerfile deleted file mode 100644 index e9c26d8..0000000 --- a/php/8.1/cli/Dockerfile +++ /dev/null @@ -1,35 +0,0 @@ -FROM alpine:3.16.0 - -LABEL maintainer="Michael Aguiar " - -RUN apk add --no-cache \ - curl \ - php81 \ - php81-bcmath \ - php81-common \ - php81-ctype \ - php81-curl \ - php81-dom \ - php81-exif \ - php81-fileinfo \ - php81-gd \ - php81-iconv \ - php81-mbstring \ - php81-mysqli \ - php81-opcache \ - php81-openssl \ - php81-pdo_mysql \ - php81-pecl-imagick \ - php81-phar \ - php81-session \ - php81-simplexml \ - php81-tokenizer \ - php81-xml \ - php81-xmlreader \ - php81-xmlwriter \ - php81-zip && \ - ln -s /usr/bin/php81 /usr/bin/php - -WORKDIR /app - -CMD ["php", "-a"] From 19e0728f3837b9741574022fb915e7cb87797323 Mon Sep 17 00:00:00 2001 From: Michael Aguiar Date: Wed, 21 Oct 2026 15:45:14 -0700 Subject: [PATCH 2/2] Tighten README and workflow wording after dropping the EOL images Say the old -latest tags are unpatched and where to move, describe the cli images without repeating 8.3-8.5 and the schedule, and drop a workflow comment parenthetical that only explained the EOL exception. --- .github/workflows/build-and-push.yml | 7 +++---- README.md | 4 ++-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-and-push.yml b/.github/workflows/build-and-push.yml index 98bee68..714faa4 100644 --- a/.github/workflows/build-and-push.yml +++ b/.github/workflows/build-and-push.yml @@ -6,10 +6,9 @@ on: # Weekly rebuild, so updates to the base images (new php.net patch # releases in the official php images; rebuilds of the pinned # dunglas/frankenphp version) and Alpine package fixes reach the tags - # without a Dockerfile change. Scheduled runs build everything (each - # build condition checks github.event_name) and skip the layer cache - # (no-cache on each build step). A new FrankenPHP release still needs - # FRANKENPHP_VERSION bumped by hand. + # without a Dockerfile change. Scheduled runs build everything and skip + # the layer cache (no-cache on each build step). A new FrankenPHP release + # still needs FRANKENPHP_VERSION bumped by hand. schedule: - cron: "0 10 * * 1" # Mondays 10:00 UTC workflow_dispatch: diff --git a/README.md b/README.md index 43869b6..0728ca1 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # docker-php -Docker images for PHP, published to `ghcr.io/aliasproject/php`. The primary offering is [FrankenPHP](https://frankenphp.dev/) (Caddy + PHP) for 8.2–8.5, plus CLI images for 8.3–8.5. Images for PHP versions past end of life (8.1 and older) are no longer built; their last `7.4/8.0/8.1-cli-latest` tags are left in the registry but get no updates. +Docker images for PHP, published to `ghcr.io/aliasproject/php`. The primary offering is [FrankenPHP](https://frankenphp.dev/) (Caddy + PHP) for 8.2–8.5, plus CLI images for 8.3–8.5. Images for PHP versions past end of life (8.1 and older) are no longer built. Their last `7.4/8.0/8.1-cli-latest` tags are left in the registry, but they're unpatched (including for CVE-2026-109618/109619); move to `8.3-cli` or newer. ## Image matrix @@ -19,7 +19,7 @@ docker pull ghcr.io/aliasproject/php:8.4-frankenphp ## Variants -- **cli** — the PHP CLI with unlimited execution time. 8.3–8.5 are built on the official `php:-cli-alpine` images, so a rebuild picks up the latest php.net patch release. 8.3–8.5 are also rebuilt weekly (Mondays 10:00 UTC), so they pick up new PHP patch releases without a Dockerfile change. PHP's ini files are in `/usr/local/etc/php` (`conf.d/` for overrides). 8.3–8.5 are identical apart from the PHP version: a minimal extension set (`pdo_mysql`, `bcmath`, `intl`, `pcntl`, `zip`, etc.), a 512M memory limit, and an unprivileged `appuser` in group `0`. Backend and library extensions (`mysqli`, `gd`, `imagick`, `redis`, `igbinary`, …) belong in a derived image such as `php/8.4/cli/Dockerfile.wordpress`. +- **cli** — the PHP CLI with unlimited execution time, built on the official `php:-cli-alpine` images, so each rebuild (including the weekly one) picks up the latest php.net patch release. PHP's ini files are in `/usr/local/etc/php` (`conf.d/` for overrides). The versions are identical apart from PHP itself: a minimal extension set (`pdo_mysql`, `bcmath`, `intl`, `pcntl`, `zip`, etc.), a 512M memory limit, and an unprivileged `appuser` in group `0`. Backend and library extensions (`mysqli`, `gd`, `imagick`, `redis`, `igbinary`, …) belong in a derived image such as `php/8.4/cli/Dockerfile.wordpress`. - **frankenphp** — FrankenPHP serves PHP directly through Caddy; no separate web server. Minimal extension set, non-root by default, mail sent through `msmtp`, Composer baked in, `HEALTHCHECK` against Caddy's admin API. - **frankenphp (dev)** — the FrankenPHP base with extra extensions (`mysqli`, `gd`, `exif`, `imagick`, `redis`, `igbinary`, `soap`) for local development. - **frankenphp (wordpress)** — the FrankenPHP base with the same extensions as `dev`, plus a hardening policy suited to running WordPress (see below).