CentOS 7.8 64bit
jenkins是使用 yum install -y jenkins 安装
一、发现问题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.26/build?
查询问题发现是使用非root用户时操作docker会提示无权限,网上搜索方法授权docker用户组都不能使用。
最后发现这样可以:
vim /usr/lib/systemd/system/jenkins.service
编辑Group=root,保存退出。
然后重新加载,重启,可行。
systemctl daemon-reload systemctl restart jenkins.service



