docker Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post
利用docker构建时,报错
+ docker pull maven:3-alpine
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.40/images/create?fromImage=maven&tag=3-alpine: dial unix /var/run/docker.sock: connect: permission denied
script returned exit code 1
解决方案
启动docker或者重启docker之后
cd /var/run
sudo chmod 666 docker.sock
欢迎关注公众号