我已经在docker cloud andrejvi/andrejvi_repo中创建了存储库,并希望将我创建的图像放置在那里。

图片名称为dev_centos32
我会推:

sudo docker push andrejvi/dev_centos32

根据我的理解,我必须为此图像创建标签。怎么做?

尝试推送:
sudo docker push andrejvi/andrejvi_repo:dev_centos32

出现错误:
An image does not exist locally with the tag: andrejvi/andrejvi_repo:

UPD

我更改了标签,但仍然无法推送到存储库
docker tag dev_centos32 andrejvi/andrejvi_repo/dev_centos32

sudo docker push andrejvi/andrejvi_repo/dev_centos32

The push refers to repository [docker.io/andrejvi/andrejvi_repo/dev_centos32]
0afb6e2f03f2: Preparing
d70d6ed6bc21: Preparing
denied: requested access to the resource is denied

UPD

登录时出错
$ sudo docker login andrejvi
Username: andrejvi
Password:
Error response from daemon: Get https://andrejvi/v2/: dial tcp: lookup andrejvi on 127.0.1.1:53: server misbehaving

最佳答案



您需要使用以下命令登录Docker Hub / Docker Cloud存储库:

docker login

看看Push images to Docker Cloud

10-07 23:44