

xdebug.ini /usr/local/etc/php/conf.d/docker-php-ext-xdebug.iniĬOPY. Install and enable XdebugĬreate or update your Dockerfile to install Xdebug and copy over the files created above.ĭepending on your image, you might need to change how you install Xdebug.ĬOPY.

We will also copy this into Docker’s /usr/local/etc/php/conf.d. Error reporting configĬreate a error reporting config file error_reporting.ini with following content: 1 We will define this host when we run our container. Notice that we are setting as host of our debug client. Configure PHP to use Xdebug and enable remote debuggingĬreate a config file named xdebug.ini that we will copy into Docker’s /usr/local/etc/php/conf.d. We need install and set it up inside our Docker container so that it can connect to a debug client running on the host machine. Xdebug is a PHP extension that needs to be installed on your container. So where is how I ended up doing it, hope it helps someone! Setup your container

Working on a pet project, I used Docker to do the heavy lifting of setting up a development environment for me.īut I struggled to find a good resource on how to setup up step by step debugging.
