3

I've installed docker engine followed by Docker Desktop following the steps mentioned at https://docs.docker.com/engine/install/ubuntu/ and https://docs.docker.com/desktop/linux/install/ubuntu/.

After the completion of installation process, I started docker desktop using command -

$ systemctl --user start docker-desktop

It stuck for hours at "Docker Desktop starting..."

Docker-Desktop

Issue when connection to docker socket

priyeshy@AMGBLR1682-LT:~$ docker run hello-world docker: Cannot connect to the Docker daemon at
unix:///home/priyeshy/.docker/desktop/docker.sock. Is the docker daemon running?. See 'docker run --help'.

priyeshy@AMGBLR1682-LT:~$ sudo docker run --rm -it hello-world [sudo] password for priyeshy: Hello from Docker! This message shows that your installation appears to be working correctly. .....

I've added my $USER in docker group and restarted using newgrp docker. Still docker run command throws same error cannot connect to docker daemon. I might be doing silly mistake but I'm unable to find.

Simon Sudler
  • 4,111
Priyesh
  • 31

1 Answers1

6

The solution is

You need to create 2 files /etc/subuid and /etc/subgid with ranges for user and group id mapping. An example:

$ echo <USER>:10000:65536 >> /etc/subuid
$ echo <USER>:10000:65536 >> /etc/subgid

I found out the solution with this GitHub issue https://github.com/docker/desktop-linux/issues/51

The solution above worked for my Manjaro system

Oyedeji
  • 61