On the Docker side, we’re done: we now must make our container and PhpStorm talk to each other. The Dockerfile is shown below:ĬOPY entrypoint.sh /usr/local/bin/entrypoint.sh RUN chmod 755 /usr/local/bin/entrypoint.sh ENTRYPOINT Setting up debugging in PhpStorm To be able to compile the extensions at build time, and to always have some useful commands at hand (in the container), I install some packages with apt-get.
These extensions are installed with the docker-php-ext-install command for debugging I need the xdebug extension, which is a PECL extension and must be installed using the pecl install command. a database ( postgresql), not relevant for the purpose of this post.įor this project I start from the Docker image php: 7.4-fpm-buster (Debian 10), and in the Dockerfile I install the PHP extensions needed for Symfony:.a webserver ( Nginx in my case, but this post applies almost unchanged to Apache).Development environmentįor a Symfony 5 application I’m developing, I’m using a docker-compose development environment made of three containers: This post is an attempt to troubleshoot all -or most- of these issues. If you are developing in PHP on Linux, using a Docker development environment, you may face issues unknown to Mac and Windows guys ?.
#Phpstorm linux how to
How to make PhpStorm’s debugger behave using Docker on Linux.