docker-magento
docker-magento copied to clipboard
xdebug not function in vs code
Currently even following the README steps, the use of xdebug for the vs code tool is not working!
Without more information is not possible to determine exactly what your issue is but for me, I discovered that it was because the Xdebug client was trying to listen on IPv6 and the container host was trying to reach out on IPv4.
In .vscode/launch.json
I use the following configuration:
{
"configurations": [
{
"name": "Listen for XDebug",
"type": "php",
"hostname": "127.0.0.1",
"request": "launch",
"stopOnEntry": true,
"log": true,
"pathMappings": {
"/var/www/html": "${workspaceFolder}"
},
"port": 9003,
}
]
}
Adding the hostname
attribute with IPv4 localhost forces the client to listen on IPv4 - wasn't able to get it to comply any other way.
what OS are you using?