From 5c23d3dcad1fe76e262e48abe247825e0faf1702 Mon Sep 17 00:00:00 2001 From: Ismo Vuorinen Date: Fri, 27 Feb 2026 08:31:31 +0200 Subject: [PATCH] feat: add CI path filters and expand README (#82) --- .github/workflows/docker-image.yml | 3 + .github/workflows/pr-build.yml | 3 + .github/workflows/pr-lint.yml | 12 ++++ README.md | 88 +++++++++++++++++++++++++++++- 4 files changed, 105 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 3e20dfa..1009fd4 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -7,6 +7,9 @@ on: - cron: "0 2 * * 1" # At 2:00 on Monday. push: branches: ["main"] + paths: + - "**/Dockerfile" + - ".github/workflows/**" workflow_dispatch: env: diff --git a/.github/workflows/pr-build.yml b/.github/workflows/pr-build.yml index 2262a66..00fca56 100644 --- a/.github/workflows/pr-build.yml +++ b/.github/workflows/pr-build.yml @@ -5,6 +5,9 @@ name: PR Build and Report on: pull_request: types: [opened, synchronize, reopened] + paths: + - "**/Dockerfile" + - ".github/workflows/**" concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/pr-lint.yml b/.github/workflows/pr-lint.yml index 36618af..1b64fe6 100644 --- a/.github/workflows/pr-lint.yml +++ b/.github/workflows/pr-lint.yml @@ -5,8 +5,20 @@ name: Lint Code Base on: push: branches: [master, main] + paths: + - "**/Dockerfile" + - ".github/workflows/**" + - ".mega-linter.yml" + - ".hadolint.yaml" + - ".yamllint.yml" pull_request: branches: [master, main] + paths: + - "**/Dockerfile" + - ".github/workflows/**" + - ".mega-linter.yml" + - ".hadolint.yaml" + - ".yamllint.yml" concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/README.md b/README.md index fcbc5cd..c984efc 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,89 @@ # docker-php-with-imagick-multi -PHP 7.4-8.5 with imagick for arm64 and amd64 +[![Build](https://github.com/ivuorinen/docker-php-with-imagick-multi/actions/workflows/docker-image.yml/badge.svg)](https://github.com/ivuorinen/docker-php-with-imagick-multi/actions/workflows/docker-image.yml) +[![License](https://img.shields.io/github/license/ivuorinen/docker-php-with-imagick-multi)](https://github.com/ivuorinen/docker-php-with-imagick-multi) +[![Last Commit](https://img.shields.io/github/last-commit/ivuorinen/docker-php-with-imagick-multi)](https://github.com/ivuorinen/docker-php-with-imagick-multi/commits/main) + +Multi-architecture Docker images for PHP 7.4 through 8.5 with Imagick and Composer pre-installed. + +## Available Images + +| PHP Version | Tag | Pull Command | +| ----------- | ------- | ------------------------------------------------------------------- | +| PHP 7.4 | `php74` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php74` | +| PHP 8.0 | `php80` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php80` | +| PHP 8.1 | `php81` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php81` | +| PHP 8.2 | `php82` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php82` | +| PHP 8.3 | `php83` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php83` | +| PHP 8.4 | `php84` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php84` | +| PHP 8.5 | `php85` | `docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php85` | + +## Architectures + +- `linux/amd64` +- `linux/arm64` + +## Included Software + +### PHP Extensions + +| Extension | Description | +| ---------- | ---------------------------------- | +| bcmath | Arbitrary precision mathematics | +| intl | Internationalization (ICU) | +| mbstring | Multibyte string handling | +| pdo | PHP Data Objects database layer | +| xml | XML parsing and manipulation | +| gd | Image processing (freetype + jpeg) | +| exif | Image metadata reading | +| pcntl | Process control | +| imagick | ImageMagick bindings (via PECL) | + +### System Libraries + +| Library | Purpose | +| ------------------ | --------------------------- | +| libicu-dev | ICU for intl extension | +| libxml2-dev | XML parsing | +| libfreetype6-dev | Font rendering (GD) | +| libjpeg62-turbo-dev| JPEG support (GD) | +| libpng-dev | PNG support (GD) | +| libonig-dev | Oniguruma regex (mbstring) | +| libmagickwand-dev | ImageMagick C API (imagick) | + +### Tools + +- **Composer** (latest, installed to `/usr/local/bin/composer`) + +## Usage + +Pull an image: + +```sh +docker pull ghcr.io/ivuorinen/docker-php-with-imagick-multi:php84 +``` + +Run a container: + +```sh +docker run --rm ghcr.io/ivuorinen/docker-php-with-imagick-multi:php84 php -v +``` + +Use as a base image in your Dockerfile: + +```dockerfile +FROM ghcr.io/ivuorinen/docker-php-with-imagick-multi:php84 +COPY . /app +WORKDIR /app +RUN composer install --no-dev +``` + +## Building Locally + +```sh +docker build -t my-php84 ./php84/ +``` + +## License + +See [LICENSE](LICENSE) for details.