我正在按照这个链接创建我的第一个docker映像,它成功了,现在我试图从这个链接将这个映像推到我的docker存储库中。但是每当我试图将这个映像推入存储库时,我就会得到这种类型的错误。
denied: requested access to the resource is denied
注:我已成功登录docker
我正在按照这个链接创建我的第一个docker映像,它成功了,现在我试图从这个链接将这个映像推到我的docker存储库中。但是每当我试图将这个映像推入存储库时,我就会得到这种类型的错误。
denied: requested access to the resource is denied
注:我已成功登录docker
当前回答
不知道docker hub发生了什么,但没有一个解决方案对我有效。以下是截至2018年1月,我最终管用的变通办法:
访问hub.docker.com并将存储库更改为private 在你的shell中:
码头工人的图片
存储库标记映像id创建大小 1.975 GB 1.955 GB 1.954 GB
docker 标签 bb38976d03cf dockhub用户名/verse_gapminder:mytag
Docker登录Docker .io
docker push dockhusersername /verse_gapminder:mytag
回到docker hub,将repo更改为public。 这对我很管用。
其他回答
不知道docker hub发生了什么,但没有一个解决方案对我有效。以下是截至2018年1月,我最终管用的变通办法:
访问hub.docker.com并将存储库更改为private 在你的shell中:
码头工人的图片
存储库标记映像id创建大小 1.975 GB 1.955 GB 1.954 GB
docker 标签 bb38976d03cf dockhub用户名/verse_gapminder:mytag
Docker登录Docker .io
docker push dockhusersername /verse_gapminder:mytag
回到docker hub,将repo更改为public。 这对我很管用。
尝试签出“Docker for Windows”应用程序和签出https://hub.docker.com/网站后执行“Docker登录”和“Docker推送”。 这对我很有帮助。
如果您已经登录,如果您仍然得到错误。请按照步骤操作,
PS C:\Users\rohit\Docker> docker logout
Removing login credentials for https://index.docker.io/v1/
PS C:\Users\rohit\Docker> docker login
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one.
Username: rohithpoya
Password:*****************
Login Succeeded
Logging in with your password grants your terminal complete access to your account.
For better security, log in with a limited-privilege personal access token. Learn more at https://docs.docker.com/go/access-tokens/
PS C:\Users\rohit\Docker> docker push rohithpoya/mongo-enterprise:5
The push refers to repository [docker.io/rohithpoya/mongo-enterprise] 83ee27b8fe98: Pushed
如果在使用Azure容器注册表时遇到此问题,可以先登录到注册表来解决。
docker login yourregistry.azurecr.io
然后标记您的映像以匹配注册表的主机名。
docker image tag yourimagename:[version] yourregistry.azurecr.io/yourimagename:[version]
最后按一下。
docker push yourregistry.azurecr.io/yourimagename:[version]
最后对我有用的唯一一件事是在dockerhub中创建一个公共存储库,并用相同的名称标记本地映像,并在合作者{in dockerhub}中添加我的userID,最后推送它。