![docker ip address ymp docker ip address ymp](https://cdn-images-1.medium.com/max/1600/1*e-j1scWWANxcjNhvek0asg.png)
I, like pretty much everyone else here, could not get Xdebug to work with such a Docker for Mac container until I disabled xdebug.remote_connect_back. I’m not totally sure if this is what’s happening, but it’s my best guess. As a result, it thinks that the request is coming from the container rather than the host. One reason could be because when you enable xdebug.remote_connect it tries to connect to 127.0.0.1:9000, which is the IP of the request according to the container, probably due to how Docker for Mac integrates the networking of the host and container. When this is on, the xdebug.remote_host setting is ignored.įor whatever reason, Docker for Mac prevents Xdebug from allowing such unrestricted connections. So, normally, you could set xdebug.remote_connect_back=on in order for Xdebug to connect to any client that makes a request to the server regardless of hostname/IP. show originalĪlright, I’d like to add my two cents to this excellent thread.
![docker ip address ymp docker ip address ymp](http://i.stack.imgur.com/Gb6qq.png)
![docker ip address ymp docker ip address ymp](https://www.ntweekly.com/wp-content/uploads/2020/05/image.png)
# Installation Of IP Alias (This survives reboot)Ĭopy/Paste the following in terminal with sudo (must be root as the target directory is owned by root). Once your machine has a well known IP address, your PHP container will then be able to connect to it, specifically XDebug can connect to it at the configured `xdebug.remote_host`. The command being run is `ifconfig lo0 alias 10.254.254.254`. This launchd script will ensure that your Docker environment on your Mac will have `10.254.254.254` as an alias on your loopback device (127.0.0.1). A startup script to standardize on using 10.254.254.254: README.md # Docker (Mac) De-facto Standard Host Address Alias