Permission denied to Docker daemon socket at unix:///var/run/docker.sock

前端 未结 5 621
感情败类
感情败类 2021-01-31 23:04

I have this Dockerfile:

FROM chekote/gulp:latest 

USER root
RUN apt-get update \\
      && apt-get upgrade -y \\
      && apt-get i         


        
5条回答
  •  隐瞒了意图╮
    2021-01-31 23:49

    A quick way to avoid that. Add your user to the group.

    sudo gpasswd -a $USER docker
    

    Then set the proper permissions.

    sudo setfacl -m user::rw /var/run/docker.sock
    

    Should be good from there.

提交回复
热议问题