moriazat
moriazat

Reputation: 11

Docker Compose (docker-compose) couldn't connect to docker daemon on Windows Server 2016 TP5

I am trying to get docker-compose to work on Windows Server 2016 TP5. I have installed Docker Desktop for Windows (not Docker Toolbox) as a service, which works perfectly. I have downloaded the latest docker-compose for windows from https://dl.bintray.com/docker-compose/master/ and put it in the same path as Docker (after unblocking the downloaded file, and renaming it to docker-compose.exe.

When I run the docker-compose up (in Powershell as an Administrator), I get the following error:

ERROR: Couldn't connect to Docker daemon. You might need to install Docker:

https://docs.docker.com/engine/installation/

Here are the docker and docker-compose information on my machine:

Docker:

Client:
Version:      1.12.1
API version:  1.24
Go version:   go1.6.3
Git commit:   23cf638
Built:        Thu Aug 18 17:52:38 2016
OS/Arch:      windows/amd64

Server:
Version:      1.12.1
API version:  1.24
Go version:   go1.6.3
Git commit:   23cf638
Built:        Thu Aug 18 17:52:38 2016
OS/Arch:      windows/amd64

Docker Compose:

docker-compose version 1.9.0dev, build f65f89a

Upvotes: 1

Views: 2286

Answers (1)

friism
friism

Reputation: 19279

You might want to try to set your DOCKER_HOST:

$ENV:DOCKER_HOST="npipe://\\.\pipe\docker_engine"

Alternatively, when registering the engine, you can make it listen on TCP too:

dockerd.exe -H npipe:////./pipe/docker_engine -H localhost:2375 --register-service

There are more details on this Compose issue

Upvotes: 2

Related Questions