From f2a8fce93f68e66fe510fde54815d0d927757950 Mon Sep 17 00:00:00 2001 From: Marvin Roman Date: Tue, 10 Dec 2024 23:01:59 +0800 Subject: [PATCH 1/5] ci: :construction_worker: changed to building imagick from source --- .kube/app/Dockerfile | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/.kube/app/Dockerfile b/.kube/app/Dockerfile index cbf898951..866a4571c 100644 --- a/.kube/app/Dockerfile +++ b/.kube/app/Dockerfile @@ -1,6 +1,7 @@ FROM php:8.4-fpm ENV PHP_VERSION 8.4 +ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version and ENV NODE_VERSION 22.11.0 ENV NVM_VERSION 0.40.1 ENV NVM_DIR /var/www/.nvm @@ -36,9 +37,29 @@ RUN apt-get install -y \ RUN docker-php-ext-configure gd --with-freetype --with-jpeg RUN docker-php-ext-install -j$(nproc) gd pdo_mysql mbstring exif pcntl bcmath bz2 zip soap intl opcache -RUN apt-get install -y libmagickwand-dev --no-install-recommends +RUN apt-get install -y \ + libmagickwand-dev \ + libmagickcore-dev \ + --no-install-recommends -RUN pecl install imagick +# START BUILDING IMAGICK FROM SOURCE - this can be removed once pecl fixes issues installing with php8.4 +RUN apt-get install -y \ + $PHPIZE_DEPS \ + libtool + +RUN mkdir -p /tmp/imagick +WORKDIR /tmp/imagick +RUN curl -L -o /tmp/imagick.tar.gz https://github.com/Imagick/imagick/archive/tags/${IMAGICK_VERSION}.tar.gz +RUN tar --strip-components=1 -xf /tmp/imagick.tar.gz +RUN phpize +RUN ./configure +RUN make +RUN make install +WORKDIR / +RUN rm -rf /tmp/imagick +# END BUILDING IMAGICK FROM SOURCE + +# RUN pecl install imagick RUN docker-php-ext-enable imagick RUN printf "\n" | pecl install apcu @@ -48,6 +69,11 @@ RUN pecl install -o -f redis && \ rm -rf /tmp/pear && \ docker-php-ext-enable redis +# - this can be removed once pecl fixes issues installing with php8.4 +RUN apt-get remove -y \ + $PHPIZE_DEPS \ + libtool + COPY --from=composer:latest /usr/bin/composer /usr/bin/composer RUN mkdir -p $NVM_DIR From 2383d1d6f62c23f6a6f9edc83912cb438013abc2 Mon Sep 17 00:00:00 2001 From: Marvin Roman Date: Wed, 11 Dec 2024 23:29:03 +0800 Subject: [PATCH 2/5] docs: :memo: updated docker comments --- .kube/app/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.kube/app/Dockerfile b/.kube/app/Dockerfile index 866a4571c..01d2fac04 100644 --- a/.kube/app/Dockerfile +++ b/.kube/app/Dockerfile @@ -1,7 +1,7 @@ FROM php:8.4-fpm ENV PHP_VERSION 8.4 -ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version and +ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped ENV NODE_VERSION 22.11.0 ENV NVM_VERSION 0.40.1 ENV NVM_DIR /var/www/.nvm From c112d1d3abdf67c834444c7b486460deb433cb53 Mon Sep 17 00:00:00 2001 From: Marvin Roman Date: Wed, 11 Dec 2024 23:35:46 +0800 Subject: [PATCH 3/5] docs: :memo: added reference to issue in comments --- .kube/app/Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.kube/app/Dockerfile b/.kube/app/Dockerfile index 01d2fac04..4686acae3 100644 --- a/.kube/app/Dockerfile +++ b/.kube/app/Dockerfile @@ -1,7 +1,7 @@ FROM php:8.4-fpm ENV PHP_VERSION 8.4 -ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped +ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped and can be removed when https://github.com/accessibility-exchange/platform/issues/2425 is resolved ENV NODE_VERSION 22.11.0 ENV NVM_VERSION 0.40.1 ENV NVM_DIR /var/www/.nvm @@ -43,6 +43,7 @@ RUN apt-get install -y \ --no-install-recommends # START BUILDING IMAGICK FROM SOURCE - this can be removed once pecl fixes issues installing with php8.4 +# see issue https://github.com/accessibility-exchange/platform/issues/2425 RUN apt-get install -y \ $PHPIZE_DEPS \ libtool From e5adff573381e72de5e90d8406914c71065cbfc4 Mon Sep 17 00:00:00 2001 From: Marvin Roman Date: Wed, 11 Dec 2024 23:38:50 +0800 Subject: [PATCH 4/5] docs: added TODOs for the removal of items --- .kube/app/Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.kube/app/Dockerfile b/.kube/app/Dockerfile index 4686acae3..211a85eae 100644 --- a/.kube/app/Dockerfile +++ b/.kube/app/Dockerfile @@ -1,6 +1,7 @@ FROM php:8.4-fpm ENV PHP_VERSION 8.4 +# TODO - IMAGICK_VERSION can be removed once pecl fixes issues installing with php8.4 ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped and can be removed when https://github.com/accessibility-exchange/platform/issues/2425 is resolved ENV NODE_VERSION 22.11.0 ENV NVM_VERSION 0.40.1 @@ -44,6 +45,7 @@ RUN apt-get install -y \ # START BUILDING IMAGICK FROM SOURCE - this can be removed once pecl fixes issues installing with php8.4 # see issue https://github.com/accessibility-exchange/platform/issues/2425 +# TODO - this can be removed once pecl fixes issues installing with php8.4 RUN apt-get install -y \ $PHPIZE_DEPS \ libtool @@ -70,7 +72,7 @@ RUN pecl install -o -f redis && \ rm -rf /tmp/pear && \ docker-php-ext-enable redis -# - this can be removed once pecl fixes issues installing with php8.4 +# TODO - this can be removed once pecl fixes issues installing with php8.4 RUN apt-get remove -y \ $PHPIZE_DEPS \ libtool From 76088ffb424fd2d47a6ea0a95fcd8572f34b697f Mon Sep 17 00:00:00 2001 From: Marvin Roman Date: Mon, 16 Dec 2024 17:03:18 +0800 Subject: [PATCH 5/5] docs: :memo: updated issue referenced in todo comments --- .kube/app/Dockerfile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.kube/app/Dockerfile b/.kube/app/Dockerfile index 211a85eae..4f603213e 100644 --- a/.kube/app/Dockerfile +++ b/.kube/app/Dockerfile @@ -2,7 +2,7 @@ FROM php:8.4-fpm ENV PHP_VERSION 8.4 # TODO - IMAGICK_VERSION can be removed once pecl fixes issues installing with php8.4 -ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped and can be removed when https://github.com/accessibility-exchange/platform/issues/2425 is resolved +ENV IMAGICK_VERSION 3.7.0 # This should be bumped to the latest version, especially when PHP version is bumped and can be removed when https://github.com/Imagick/imagick/issues/698 is resolved ENV NODE_VERSION 22.11.0 ENV NVM_VERSION 0.40.1 ENV NVM_DIR /var/www/.nvm @@ -44,8 +44,7 @@ RUN apt-get install -y \ --no-install-recommends # START BUILDING IMAGICK FROM SOURCE - this can be removed once pecl fixes issues installing with php8.4 -# see issue https://github.com/accessibility-exchange/platform/issues/2425 -# TODO - this can be removed once pecl fixes issues installing with php8.4 +# TODO - this can be removed when https://github.com/Imagick/imagick/issues/698 is resolved RUN apt-get install -y \ $PHPIZE_DEPS \ libtool @@ -72,7 +71,7 @@ RUN pecl install -o -f redis && \ rm -rf /tmp/pear && \ docker-php-ext-enable redis -# TODO - this can be removed once pecl fixes issues installing with php8.4 +# TODO - this can be removed when https://github.com/Imagick/imagick/issues/698 is resolved RUN apt-get remove -y \ $PHPIZE_DEPS \ libtool