Docker looks for the daemon socket in the wrong place

I installed docker with pacman, enabled docker.service and added my user to the docker group Now with the daemon running I’m not able to use docker without sudo. docker version prints the info for the client then this message:

Cannot connect to the Docker daemon at unix:///home/toby/.docker/desktop/docker.sock. Is the docker daemon running?

I think it ought to be looking for the socket in /var/run/docker.sock so how can I fix that?

I’m running Manjaro Sway on a machine that also has Ubuntu installed. They are sharing a home partition. In Ubuntu I had Docker Desktop installed, but I’ve removed and purged that from Ubuntu, but still I get the error message in Manjaro.

I’ve tried grepping for any occurrence of the string “desktop/docker.sock” in the home partition, but nothing that came up looks relevant.

Check the config files in ~/.docker and delete them.

You can also do a docker context ls and then choose with docker context use [contextName] it might be docker context use default

Thanks. docker context use default worked.

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