ot permission denied while trying to connect to the Docker daemon socket at

错误:

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.24/containers/json: dial unix /var/run/docker.sock: connect: permission denied

 添加docker用户组

sudo groupadd docker

将当前用户加入docker组 

 sudo gpasswd -a ${USER} docker

 重启docker服务

 service docker restart 

 

你可能感兴趣的:(Linux,docker,运维,linux)