我已经在Amazon Linux AMI上构建了代理机器。它具有docker容器jetbrains/teamcity-agent:latest
。我可以在TeamCity面板中看到构建代理。
当我尝试使用docker build / push命令运行build时,出现此错误
Cannot login to registry docker.io (new); cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?; exit code 1 (Step: docker build (Docker))
teamcity-agent
怎么了?
答案 0 :(得分:0)
我猜想jetbrains/teamcity-agent:latest
将以没有docker权限的用户身份运行。需要将在此映像中运行命令的用户添加到组docker,或者通过ACL授予对docker套接字/var/run/docker.sock
的权限。请注意,这等效于root
。