From cf8490f3a043e6132eadd5fda77f42257be129c9 Mon Sep 17 00:00:00 2001 From: Julian Liebig Date: Wed, 3 Jan 2024 13:53:31 +0100 Subject: [PATCH] Fix xdebug incompatibility with php 7.4 --- node-php/7.4/buster/apache/Dockerfile | 2 +- node-php/7.4/buster/cli-composer/Dockerfile | 2 +- node-php/7.4/buster/cli-composer2/Dockerfile | 2 +- node-php/7.4/buster/fpm/Dockerfile | 2 +- node-php/builder/build.sh | 6 ++++++ 5 files changed, 10 insertions(+), 4 deletions(-) diff --git a/node-php/7.4/buster/apache/Dockerfile b/node-php/7.4/buster/apache/Dockerfile index a220b67..fa65d9f 100644 --- a/node-php/7.4/buster/apache/Dockerfile +++ b/node-php/7.4/buster/apache/Dockerfile @@ -28,7 +28,7 @@ RUN requirements="nodejs npm msmtp libmcrypt-dev libwebp-dev libmcrypt4 libcurl3 && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* # Install xdebug (based on https://gist.github.com/chadrien/c90927ec2d160ffea9c4) -RUN yes | pecl install xdebug +RUN yes | pecl install xdebug-3.1.6 # Install yaml RUN yes | pecl install yaml && echo "extension=yaml.so" > /usr/local/etc/php/conf.d/ext-yaml.ini diff --git a/node-php/7.4/buster/cli-composer/Dockerfile b/node-php/7.4/buster/cli-composer/Dockerfile index eb1b2f5..74cefae 100644 --- a/node-php/7.4/buster/cli-composer/Dockerfile +++ b/node-php/7.4/buster/cli-composer/Dockerfile @@ -28,7 +28,7 @@ RUN requirements="nodejs npm msmtp libmcrypt-dev libwebp-dev libmcrypt4 libcurl3 && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* # Install xdebug (based on https://gist.github.com/chadrien/c90927ec2d160ffea9c4) -RUN yes | pecl install xdebug +RUN yes | pecl install xdebug-3.1.6 # Install yaml RUN yes | pecl install yaml && echo "extension=yaml.so" > /usr/local/etc/php/conf.d/ext-yaml.ini diff --git a/node-php/7.4/buster/cli-composer2/Dockerfile b/node-php/7.4/buster/cli-composer2/Dockerfile index 0e8cf83..3993256 100644 --- a/node-php/7.4/buster/cli-composer2/Dockerfile +++ b/node-php/7.4/buster/cli-composer2/Dockerfile @@ -28,7 +28,7 @@ RUN requirements="nodejs npm msmtp libmcrypt-dev libwebp-dev libmcrypt4 libcurl3 && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* # Install xdebug (based on https://gist.github.com/chadrien/c90927ec2d160ffea9c4) -RUN yes | pecl install xdebug +RUN yes | pecl install xdebug-3.1.6 # Install yaml RUN yes | pecl install yaml && echo "extension=yaml.so" > /usr/local/etc/php/conf.d/ext-yaml.ini diff --git a/node-php/7.4/buster/fpm/Dockerfile b/node-php/7.4/buster/fpm/Dockerfile index d695a4f..b4a0d1e 100644 --- a/node-php/7.4/buster/fpm/Dockerfile +++ b/node-php/7.4/buster/fpm/Dockerfile @@ -28,7 +28,7 @@ RUN requirements="nodejs npm msmtp libmcrypt-dev libwebp-dev libmcrypt4 libcurl3 && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* # Install xdebug (based on https://gist.github.com/chadrien/c90927ec2d160ffea9c4) -RUN yes | pecl install xdebug +RUN yes | pecl install xdebug-3.1.6 # Install yaml RUN yes | pecl install yaml && echo "extension=yaml.so" > /usr/local/etc/php/conf.d/ext-yaml.ini diff --git a/node-php/builder/build.sh b/node-php/builder/build.sh index 3bae5c1..80bbb01 100755 --- a/node-php/builder/build.sh +++ b/node-php/builder/build.sh @@ -38,6 +38,12 @@ for goal in */*/*; do fi sed -e "s/\@@gd_requirements@@/$GD_OPTIONS/" -i "$version/$base/$variant/Dockerfile" + # If php 7.4: Install xdebug 3.1.6 + if [[ "7.4" == "$version" ]] + then + sed -e "s/pecl install xdebug/pecl install xdebug-3.1.6/" -i "$version/$base/$variant/Dockerfile" + fi + # If apache: Copy Vhost and add it if [[ "apache" == "$variant" ]] then