Last active
December 20, 2022 08:48
-
-
Save mingalevme/d834e74ebb8c71fc5b938222acc98438 to your computer and use it in GitHub Desktop.
PHP 5.4 Docker + Xdebug + Composer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM php:5.4 | |
RUN apt-get update && apt-get upgrade -y | |
RUN apt-get install -y zlib1g-dev libzip-dev unzip && \ | |
curl --insecure "https://getcomposer.org/download/latest-2.2.x/composer.phar" > "/usr/local/bin/composer" && \ | |
chmod a+x "/usr/local/bin/composer" && \ | |
cd /opt && \ | |
curl --insecure -O https://xdebug.org/files/xdebug-2.4.1.tgz && \ | |
tar -xvf xdebug-2.4.1.tgz && \ | |
cd xdebug-2.4.1 && \ | |
phpize && \ | |
./configure --enable-xdebug && \ | |
make && \ | |
make install && \ | |
echo "zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts-20100525/xdebug.so" > /usr/local/etc/php/conf.d/xdebug.ini |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM php:7.4-fpm | |
RUN apt-get update && apt-get upgrade -y | |
RUN curl --insecure "https://getcomposer.org/download/2.4.4/composer.phar" > "/usr/local/bin/composer" && \ | |
chmod a+x "/usr/local/bin/composer" && \ | |
cd /opt && \ | |
curl --insecure -O https://xdebug.org/files/xdebug-3.1.6.tgz && \ | |
tar -xvf xdebug-3.1.6.tgz && \ | |
cd xdebug-3.1.6 && \ | |
phpize && \ | |
./configure --enable-xdebug && \ | |
make && \ | |
make install && \ | |
echo "zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts-20190902/xdebug.so" > /usr/local/etc/php/conf.d/xdebug.ini |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment