-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to debug this application in PhpStorm #1
Comments
@dzschille Thanks! I feel like I'm almost there. I went back and started fresh from your instructions without doing any of the Docker integration stuff in IntelliJ. I followed your instructions and it's not working for me yet -- one thing I notice in my IntelliJ is that when I click on the "Start listening for PHP Debug Connections" button, the square "Stop" button next to it doesn't turn red as it does in your IDE. I'm going to research that and see what might be going on. I may be missing a setting or something. |
@Holodny when I click on the "Start listening for PHP Debug Connections" button, the square "Stop" button next to it doesn't turn red directly. It turns red when the debug session started, so after reloading the web page and the reaction of PhpStorm. I also updated my HowTo: when you have changed to Xdebug remote host IP in your docker-compose.yml, you have to start the containers with You can verify if the setting is active like this:
|
@dzschille Ok, I tried it with PHPStorm and had the same results with a new project. I'm going to try some simpler projects with just PHP & maybe Apache and no configuration changes and see how that works. I'll update here and at the phpdocker.io repository with my results. Thanks so much Dzschille! |
@Holodny , i don't think it has to do with the project code. When no debug session starts it has mostly to do with the Xdebug config, and the IP to connect back. Have you checked your IP in the webserver container?: |
@dzschille , Yah, I did that and added that IP to the yml file as in your example. I went through your instructions step by step for PHPStorm. I may be missing something. I'm looking at where other people have mentioned aliasing the host IP address also. |
My steps how i could debug the app:
First consideration: in phpdocker/php-fpm/php-ini-overrides.ini i set xdebug.remote_port to 9000 which is xdebugs default.
An other option would be to change the port in PhpStorms debug configuration.
How to start the app:
Now take this IP and set it in docker-compose.yml as value XDEBUG_CONFIG. Then you have to stop your docker containers and start them with
docker-compose up -d
again. You have to use "up" because "start" does not handle the config change.The text was updated successfully, but these errors were encountered: