![]() He mentions rootless docker but at least he seems to have some logs. The mention of "rootless docker" is his last comment. This guy is having a similar sort of issue. Just a random thought that helped me in the past. That's in case if you are executing the wrong URL or file was not updated there. ![]() print IP or server name etc (something unique that will allow you to differentiate one system from another). I'm sure it went through it as it was right before my phpinfo() which appears on screen.Īlways add some unique code that can confirm that it is run on the right system. I also tried to place a xdebug_break() in the code. ![]() Too bad you have to stick to Xdebug v2 - v3 has easier ways of troubleshooting. You need Xdebug log to confirm what it is doing. Check this one (not sure if it will help with container though). In those threads where I was suggesting it (and that was ordinary system, not virtual) it was helping. but going to mention it anyway ( sudo setsebool -P httpd_can_network_connect=1 ). I do not think you have SELinux or alike in Docker containers. using fwrite() or alike)? To check that it can write there.Ģ. So I tried /tmp/xdebug but it doesn't work either.ġ. Given that xdebug configs are almost identical between my local server and my Docker container, that Storm debug validation is successful on both servers, that my Storm for the project in Docker catches the xdebug connection when I load the project on my local server (although as an external connection since it's not from the Docker server address), I'm guessing something is lost somewhere inside Docker but I'm not really sure anymore. Here is my xdebug config on Docker container: xdebug xdebug support I run Docker in rootless mode but when I go to Build, Execution, Deployment>Docker and configure my Docker, the connection is successful. When I try to validate my debug configuration in Storm for the docker version, is found and everything is ok. I compared the xdebug configuration in phpinfo between my local server and the container, both are strictly identical (except for remote_host, it's localhost on my local server, and the log paths). Now, when I run the exact same project with Docker, everything works fine but my breakpoint doesn't trigger anything. When I set up PHP>Debug and validate my configuration for xdebug, it is ok.When I enable Chrome xdebug extension and start listening for debug connections in Storm, my breakpoint (at the very start of the page execution) is catched and I can debug. I can run the project on a local apache+php5.6+xdebug2.5.5 and it works fine. I'm working on a project running on PHP 5.6, with cakePHP. All of that worked but still the debugger didn't work.I'm on ubuntu 20, runing the latest stable PHPStorm. I also did a ping to my host machine from within the container to test if there's a connection and a telnet to test for port 9000. Any ideas why this is not working?Īnyways I tried this already before with different settings including the and my actual IP address. The other two settings from my still apply though. But now when I docker-compose down and up again it doesn't change in the phpinfo anymore. I am pretty sure this was added to the config correctly before. Th app is running inside docker and remote_host should be set to by my docker-compose.yml that I have attached above, for some reason this line doesn't seem to have any effect anymore XDEBUG_CONFIG: remote_host= XDEBUG_CONFIG: remote_log=/var/log/apache2/xdebug.log docker-images/php/vhosts/:/etc/apache2/sites-enabled docker-images/php/php.ini:/usr/local/etc/php/php.ini This is the output of my phpinfo xdebug support Now when I activate this extension and set phpstorm to listen for incoming php debug connections and set a few breakpoints, when I reload the page nothing happens. I also installed the browser extension for chrome. When I go to Preferences -> PHP > Debug and Validate the debugger configuration (as a local web server) this works and gives me the following output: Now as the last thing I tried to set up Xdebug, which isn't working. Now I set this up in PHPStom as a local webserver (because it's running on 127.0.0.1:80 and the sourcecode is mounted as a volume) I have a magento project set up in a docker-compose with two services: php-apache7.2 and mariadb10.1.36
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |