From 06090cd57fd835fb38effd51cfa115e058d1d9f1 Mon Sep 17 00:00:00 2001 From: tuutti Date: Mon, 14 Oct 2024 08:36:02 +0300 Subject: [PATCH] Log xdebug errors to a file --- php/files/entrypoints/15-xdebug.sh | 1 + php/files/etc/php/conf.d/xdebug.ini | 1 + 2 files changed, 2 insertions(+) diff --git a/php/files/entrypoints/15-xdebug.sh b/php/files/entrypoints/15-xdebug.sh index fe82a54..4d7a974 100644 --- a/php/files/entrypoints/15-xdebug.sh +++ b/php/files/entrypoints/15-xdebug.sh @@ -8,6 +8,7 @@ if [ "$XDEBUG_ENABLE" = "true" ]; then echo "- Already enabled..." else sudo mv "$XDEBUG_INI".disabled "$XDEBUG_INI" + sudo -u root touch /tmp/xdebug.log && sudo chmod 666 /tmp/xdebug.log fi else echo "- Start with Xdebug disabled. Add XDEBUG_ENABLE=true ENV variable to enable it." diff --git a/php/files/etc/php/conf.d/xdebug.ini b/php/files/etc/php/conf.d/xdebug.ini index 4b32e03..d013a1a 100644 --- a/php/files/etc/php/conf.d/xdebug.ini +++ b/php/files/etc/php/conf.d/xdebug.ini @@ -3,3 +3,4 @@ zend_extension=xdebug.so xdebug.mode=debug xdebug.client_host=host.docker.internal xdebug.idekey=PHPSTORM +xdebug.log=/tmp/xdebug.log