Docker version: Running 2 sites/containers at same time #1393
Comments
@rfay - Yeah... I ran into that last week as well, just didn't have any time to post an issue for it. I got so excited I could alias an IP address to localhost... that I forgot that Docker was still just using localhost and binding to port 80 on Which means the Docker-based solution will definitely have to wait (if you do anything else with port 80/443 on your local machine) until moby/moby#22753 is fixed. At least that's how I'm currently reading the situation. Maybe there's some better solution using the |
Thanks! Maybe docker will get their act together before long :) |
It would be nice if Docker for Mac worked like Docker for Linux (and most of the time, Docker for Windows) works with regard to networking—apparently it's mostly a solved problem in 10.12, but Docker for Mac doesn't include full support for bridge networking on Mac because it's supported for 10.10 and 10.11 still :/ |
Eek, another annoying thing I uncovered today—if you forget to delete the alias and try using the same IP address for something else (e.g. a Vagrant box), then it'll screw with networking a bit. So I updated the Docker instructions to:
|
I'm going to close this as a known issue for now—basically you can only run one Drupal VM Docker instance at a time if you're on Mac or Windows (for Linux, it should work with more than one). Hopefully it gets fixed upstream by Docker for Mac/Windows networking getting a bit more intelligent, but it seems that until Docker CE drops support for 10.11 or 10.12, the networking layer will be missing some major required improvements :( |
Issue Type
Your Environment
, docker-compose
docker-compose version 1.13.0, build 1719ceb
Your OS
Summary
I was trying to see what would happen with the docker version of drupalvm and having 2 sites up at one time, but it didn't appear to be possible. Although I changed the network ranges so they didn't overlap and the IPs in there, it still failed on port binding, for example:
It appears that it's still not possible for docker-for-mac to bind to the same port on different IP addresses for different containers?
Attached are the two docker-compose files that I used (in zip)
composefiles.zip
The text was updated successfully, but these errors were encountered: