试图将图像推送到docker注册表

时间:2016-05-11 17:14:07

标签: docker docker-compose

我正在尝试将docker镜像推送到docker hub(注册表)但我收到错误。这会是什么问题?

   root@ubuntu-512mb-nyc2-01:~# 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 : 
Password: 
Login Succeeded
root@ubuntu-512mb-nyc2-01:~# docker push nodevolume/new:0.1
The push refers to a repository [docker.io/nodevolume/new]
c5bcc1df7ac9: Preparing 
6f6073c5df6d: Preparing 
dec9270df6f5: Preparing 
9f7fef8e5d59: Preparing 
346f6530205e: Preparing 
98a7412556fb: Waiting 
7598955b0d14: Waiting 
5f70bf18a086: Waiting 
5b5be35aaec4: Waiting 
4e2fee1e7083: Waiting 
1822b2b47122: Waiting 
7394707b3914: Waiting 
unauthorized: authentication required
root@ubuntu-512mb-nyc2-01:~# 

在我的日志中显示:

    time="2016-05-11T12:45:31.133777251-04:00" level=error msg="Upload failed: unauthorized: authentication required" 
time="2016-05-11T12:45:31.136657146-04:00" level=error msg="Upload failed: unauthorized: authentication required" 
time="2016-05-11T12:45:31.138376928-04:00" level=error msg="Upload failed: unauthorized: authentication required" 
time="2016-05-11T12:45:31.140385526-04:00" level=error msg="Upload failed: unauthorized: authentication required" 
time="2016-05-11T12:45:31.141045576-04:00" level=error msg="Attempting next endpoint for push after error: unauthorized: authentication required" 
time="2016-05-11T13:11:48.838177306-04:00" level=error msg="Upload failed: unauthorized: authentication required" 
time="2016-05-11T13:11:48.839113848-04:00" level=error msg="Attempting next endpoint for push after error: unauthorized: authentication required" 
root@ubuntu-512mb-nyc2-01:~#

NODE VERSION - 这是我正在使用的节点的版本。如何判断我是否具有推送到Docker Hub的正确权限?

    Client:
 Version:      1.11.1
 API version:  1.23
 Go version:   go1.5.4
 Git commit:   5604cbe
 Built:        Tue Apr 26 23:30:23 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.11.1
 API version:  1.23
 Go version:   go1.5.4
 Git commit:   5604cbe
 Built:        Tue Apr 26 23:30:23 2016
 OS/Arch:      linux/amd64

1 个答案:

答案 0 :(得分:0)

您正试图推送到您无法访问的帐户; nodevolume/new存储库指的是Docker Hub上的nodevolume帐户(但该帐户不存在)。将其更改为<your-hub-account>/new,您应该能够推送图像。