Add Docker Xdebug troubleshooting#19
Open
subhajitlucky wants to merge 1 commit into
Open
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a troubleshooting section to the Docker Xdebug guide to help diagnose cases where Xdebug is installed but breakpoints are not being hit, improving the Docker environment documentation.
Changes:
- Adds checks to confirm Xdebug is loaded, and guidance for selecting the correct
xdebug.client_hostin Docker Desktop vs native Linux. - Adds guidance for matching Xdebug 3 port settings with IDE configuration.
- Adds steps for enabling/inspecting Xdebug logs, verifying mounted config, and debugging CLI/tests with
PHP_IDE_CONFIG.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+105
to
+109
| Create a writable log path inside the container: | ||
|
|
||
| ```bash | ||
| touch /tmp/xdebug.log | ||
| chmod 666 /tmp/xdebug.log |
| Reload the container and inspect the log after making a request: | ||
|
|
||
| ```bash | ||
| docker compose restart |
Comment on lines
+93
to
+100
| ## Match the IDE Port | ||
| Xdebug 3 commonly uses port `9003`, while older examples often use `9000`. Make sure the port in `xdebug.ini` matches the port your IDE listens on: | ||
|
|
||
| ```ini | ||
| xdebug.client_port=9003 | ||
| ``` | ||
|
|
||
| If you keep `9000`, update the IDE debug port to `9000` as well. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #17
Adds a troubleshooting section to the Docker Xdebug guide covering:
Validation: