Problem
So you've got your docker up and running but on some day it says
Got permission denied while trying to connect to the
Docker daemon socket at unix:///var/run/docker.sock:
Get http://%2Fvar%2Frun%2Fdocker.sock/v1.40/images/json:
dial unix /var/run/docker.sock:
connect: permission denied
your user is already in docker
group, so
sudo usermod -aG docker $USER
doesn't help
Solution
Bad:
sudo chmod 777 /var/run/docker.sock
Good:
sudo setfacl --modify user:$USER:rw /var/run/docker.sock
Top comments (0)