From b571e1938b8628192677c9cdfc4c369b4a2457e1 Mon Sep 17 00:00:00 2001 From: myrmidex Date: Sat, 15 Aug 2026 01:22:18 +0200 Subject: [PATCH] 147 - Add gd to the CI image and declare ext-gd --- composer.json | 1 + composer.lock | 5 +++-- docker/build/Dockerfile.ci | 12 +++--------- 3 files changed, 7 insertions(+), 11 deletions(-) diff --git a/composer.json b/composer.json index 0254fbae..99b45229 100644 --- a/composer.json +++ b/composer.json @@ -14,6 +14,7 @@ "license": "AGPL-3.0-only", "require": { "php": "^8.2", + "ext-gd": "*", "blade-ui-kit/blade-heroicons": "^2.6", "laravel/framework": "^12.0", "laravel/horizon": "^5.29", diff --git a/composer.lock b/composer.lock index 665abac6..fabaf870 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "e6ce5effb7f8c4d5a3f6d8cd04b6e299", + "content-hash": "67923d1e9e79798f3ebe2e79954f4795", "packages": [ { "name": "blade-ui-kit/blade-heroicons", @@ -8747,7 +8747,8 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^8.2" + "php": "^8.2", + "ext-gd": "*" }, "platform-dev": {}, "plugin-api-version": "2.6.0" diff --git a/docker/build/Dockerfile.ci b/docker/build/Dockerfile.ci index 05481602..b63abaf4 100644 --- a/docker/build/Dockerfile.ci +++ b/docker/build/Dockerfile.ci @@ -2,21 +2,15 @@ # Tests run against sqlite in memory (see .env.testing), so no database client # or cache extension is needed. # -# Extensions here are the ext-* requirements from composer.lock that php:alpine -# does not already bundle. Regenerate that list before changing this file. +# php:alpine already bundles the rest of what composer.lock requires. gd is not +# declared anywhere but ThumbnailUploader calls it directly. FROM php:8.3-alpine COPY --from=mlocati/php-extension-installer:2 /usr/bin/install-php-extensions /usr/local/bin/ RUN install-php-extensions \ - pdo_sqlite \ - mbstring \ - dom \ - xml \ - fileinfo \ - iconv \ pcntl \ - posix + gd # nodejs is not used by the app's tests; the Forgejo/GitHub JavaScript actions # (checkout, cache) are executed with it inside this container.