Docker从工件中拉出失败并出现凭据问题 [英] Docker pull from artifactory fails with credentials issue

查看:108
本文介绍了Docker从工件中拉出失败并出现凭据问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在远程环境中有一个Jenkins作业,在该环境中,我使用docker从本地Artifactory存储库中提取图像(microsoft/aspnetcore-build/2.0.0),但是docker pull失败并显示-'unknown:Forbidden',但其他作业共享相同的Artifactory凭据不会失败.
仅当从我的本地计算机或任何其他计算机上尝试执行docker pull似乎才继续进行,然后在Jenkins上手动启动该作业.每个图像层都有多次重试,随后失败,并显示-

I have a Jenkins job on a remote environment where I use docker to pull down an image (microsoft/aspnetcore-build/2.0.0) from a local Artifactory repo, but the docker pull fails with - 'unknown: Forbidden', yet other jobs sharing the same Artifactory credentials do not fail.
The docker pull seems to proceed only when attempted from my local or any other machine, and then the job is kicked off manually on Jenkins. There are multiple retries for each image layer and subsequently it fails with -

'未知:拒绝工件下载请求:用户xyz不是 允许部署"microsoft/aspnetcore-build/2.0.0".

'unknown: Rejected artifact download request: User xyz is not permitted to deploy 'microsoft/aspnetcore-build/2.0.0'.

推荐答案

尝试添加docker login -u $DOCKER_USER -p $DOCKER_PW $DOCKER_URL以确保您已经登录

try add docker login -u $DOCKER_USER -p $DOCKER_PW $DOCKER_URL to make sure you already loggin

这篇关于Docker从工件中拉出失败并出现凭据问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆