【发布时间】:2015-06-12 16:28:15
【问题描述】:
我在从 Dockerfile 构建映像时尝试克隆存储库。我正在使用sequenceiq/docker-spark Dockerfile 并将其扩展如下(在ENTRYPOINT 行之前):
RUN yum install -y git
RUN git clone git@github.com:myorg/myrepo.git
几分钟后我收到以下错误:
Initialized empty Git repository in /myrepo/.git/
fatal: The remote end hung up unexpectedly
INFO[0128] The command [/bin/sh -c git clone git@github.com:myorg/myrepo.git] returned a non-zero code: 128
我已将图像的 id_rsa.pub 添加到该存储库的部署密钥中。我尝试在图像上运行bash 并尝试在相同的问题上运行git clone-ing。我难住了。我发现了这个相关问题here,但我的 ssh 密钥没有密码,所以没有帮助。
【问题讨论】: