Could not connect to docker error (solved)

Docker is throwing an error… I have no idea how to get past this. Any help is appreciated. Note that I don’t think it matters, but I don’t currently have a DNS on this server… it’s behind a DMZ. Docker appears to be working correctly though.

bfadmin@signage:/opt/xibo/xibo-docker$ docker-compose up -d
ERROR: Couldn't connect to Docker daemon at http+docker://localunixsocket - is it running?

If it's at a non-standard location, specify the URL with the DOCKER_HOST environment variable.
bfadmin@signage:/opt/xibo/xibo-docker$ docker-compose --version
docker-compose version 1.13.0, build 1719ceb
bfadmin@signage:/opt/xibo/xibo-docker$ sudo docker run hello-world

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
 1. The Docker client contacted the Docker daemon.
 2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
 3. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
 4. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.

My mistake… forgot sudo! Should be “sudo docker-compose up -d”

2 Likes

I was just about to ask this same question, thank you for posting your answer! dang sudo lol

sudo as you say, or grant the user you work as permissions to use the docker engine (I believe by adding them to the docker group).

good idea, probably better for the long run!