Unable to run docker as me but works as superuser

I'm trying to get docker working. The systemctl command shows that the docker daemon is running. When I do "sudo docker run hello-world", all is well. When I run "docker run hello-world", I get this error:

docker: Cannot connect to the Docker daemon at unix:///home/ian/.docker/desktop/docker.sock. Is the docker daemon running?.
See 'docker run --help'.

I've seen a post install step (in documentation) where I add myself to the docker group and reboot, login and try "docker run hello-world" again. I'm sure I've done that on PopOs! and Ubuntu and that worked in the past. When I do that process now, I get no errors, but I still can't run containers as me. It must be a permissions thing, I just don't know what to do. I was really looking forward to learning MongoDb in a container, but now I'm stumped.

I'm not sure how to uninstall and clean up docker and try again, other whether I'm facing a wipe and reinstall. (I hope not).

Uname -a reports "Linux ian-ThinkPad-T430s 5.15.0-48-generic #54~20.04.1-Ubuntu SMP Thu Sep 1 16:17:26 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
"

docker --version reports "Docker version 20.10.18, build b40c2f6"

The reason for requiring an admin session is that the Docker client in the default configuration uses a named pipe to connect to the Docker engine and that named pipe can only be accessed by administrators

If you are not satisfied with the solution you can create the same request at the Docker Forum :wink:

I've completely wiped docker from my computer. Re-installed it and its working.

2 Likes

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.