Docker Community Forums

Share and learn in the Docker community.

Docker compose is extremely slow

docker
dns

(Sebastian Porto) #1

Expected behavior

To run immediately

Actual behavior

Takes several minutes to run

Steps to reproduce the behavior

Since I installed Docker beta for Mac, docker-compose has become unusable slow. Simply doing something like:

docker-compose --verbose run app /bin/bash

Takes minutes. Every step in the verbose output e.g. compose.cli.verbose_proxy.proxy_callable: docker inspect_container hangs for about 30 seconds.


Docker-compose un-usable on Mac Beta
Docker-compose hangs
(Dave Tucker) #2

Hi,

Thanks for your feedback and sorry you’re having problems with Docker for Mac.
Do you have a sample docker-compose.yml file we could try this with to see where the issue lies?

Thanks!

– Dave


(Sebastian Porto) #3

Hi Dave

This seems to do with changing networks. When I try using docker-compose in my office it runs as expected. At home it stalls. I remember issues like this with boot2docker. Then it was all fine using docker machine. Any clues?

Thanks


(Sebastian Porto) #4

This is an example docker-compose.yml

hello:
  image: hello-world

I do this time docker-compose --verbose up

And it takes minutes to run.

However if I turn the wifi off on my laptop it runs immediately. I’m using a Mac Book Pro, El Capitan 10.11.4

Thanks


(Sebastian Porto) #5

Changing my DNS server provide to Google DNS 8.8.8.8 fixes this issue, no idea why.


(Ralphschindler) #6

Incidentally, I had this problem this morning as well, yesterday I was on a different network.
I’ve noticed slowness issues with docker.local resolving, perhaps this is related, perhaps not. My local router uses 8.8.8.8 for resolution, and oddly, after changing my local dns to use 8.8.8.8 instead of the dns on the router, everything cleared up (I also switched to using port forarding instead of using docker.local).


(Frenchben) #7

(Frenchben) #8