在本地向VirtualBox里的CoreOS推送镜像,为何不可?

在MacOS里安装Docker,版本:

Client:
 Version:      17.09.0-ce
 API version:  1.32
 Go version:   go1.8.3
 Git commit:   afdb6d4
 Built:        Tue Sep 26 22:40:09 2017
 OS/Arch:      darwin/amd64

Server:
 Version:      17.09.0-ce
 API version:  1.32 (minimum version 1.12)
 Go version:   go1.8.3
 Git commit:   afdb6d4
 Built:        Tue Sep 26 22:45:38 2017
 OS/Arch:      linux/amd64
 Experimental: true

在VirtualBox上安装CoreOS(CentOS也一样)并运行Docker Registry。在其中自测OK:

$ curl http://172.17.8.101:5000/v2/_catalog
{"repositories":[]}

172.17.8.101是CoreOS的IP。

在本地做新tag:

$ docker tag ubuntu 172.17.8.101:5000/myfirstimage

向CoreOS推送:

$ docker push 172.17.8.101:5000/myfirstimage

有下面的错误:

The push refers to a repository [172.17.8.101:5000/myfirstimage]
Get https://172.17.8.101:5000/v2/: dial tcp 172.17.8.101:5000: getsockopt: no route to host

可以从本地ping到CentOS,但为什么不能推送?

阅读 2.7k
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题