diff --git a/bin/xdebug-on.sh b/bin/xdebug-on.sh index f9d6dc5eb0..c020645025 100755 --- a/bin/xdebug-on.sh +++ b/bin/xdebug-on.sh @@ -2,7 +2,12 @@ set -e -docker-php-ext-enable xdebug -pkill -o -USR2 php-fpm -touch /app/.xdebug-enabled -echo "Xdebug enabled" +if [ ! -e /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini ]; then + docker-php-ext-enable xdebug + echo "xdebug.start_with_request=yes" >> /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini + pkill -o -USR2 php-fpm + touch /app/.xdebug-enabled + echo "Xdebug enabled" +else + echo "Xdebug already enabled" +fi diff --git a/php.ini b/php.ini index 3f44dddc74..79824f3456 100644 --- a/php.ini +++ b/php.ini @@ -1,5 +1,2 @@ -xdebug.remote_enable = 1 -xdebug.remote_autostart = 0 -xdebug.remote_connect_back = 0 -xdebug.remote_port=9000 html_errors = 1 +xdebug.start_with_request = yes