@UlricQin 你好,想跟你请教个问题:server在pull image时报错,如下:
2015/02/27 14:21:32 compare.go:252: create container. app:app, ip:10.1.1.250
2015/02/27 14:21:32 compare.go:299: [ERROR] pull image 127.0.0.1:5000/dsds/n24:0.1 fail: API error (500): Invalid Registry endpoint: Get http://127.0.0.1:5000/v1/_ping: dial tcp 127.0.0.1:5000: connection refused
$ curl http://127.0.0.1:5000/v1/_ping的结果如下
{"host": ["Linux", "ubuntu14", "3.13.0-24-generic", "#46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014", "x86_64", "x86_64"], "launch": ["/usr/local/bin/gunicorn", "--access-logfile", "-", "--error-logfile", "-", "--max-requests", "100", "-k", "gevent", "--graceful-timeout", "3600", "-t", "3600", "-w", "4", "-b", "0.0.0.0:5000", "--reload", "docker_registry.wsgi:application"], "versions": {"M2Crypto.m2xmlrpclib": "0.22", "SocketServer": "0.4", "argparse": "1.1", "backports.lzma": "0.0.3", "blinker": "1.3", "cPickle": "1.71", "cgi": "2.6", "ctypes": "1.1.0", "decimal": "1.70", "distutils": "2.7.6", "docker_registry.app": "1.0.0-dev", "docker_registry.core": "2.0.3", "docker_registry.server": "1.0.0-dev", "email": "4.0.3", "flask": "0.10.1", "gevent": "1.0.1", "greenlet": "0.4.5", "gunicorn": "19.1.1", "gunicorn.arbiter": "19.1.1", "gunicorn.config": "19.1.1", "gunicorn.six": "1.2.0", "jinja2": "2.7.3", "json": "2.0.9", "logging": "0.5.1.2", "parser": "0.5", "pickle": "$Revision: 72223 $", "platform": "1.0.7", "pyexpat": "2.7.6", "python": "2.7.6 (default, Mar 22 2014, 22:59:56) \n[GCC 4.8.2]", "re": "2.2.1", "redis": "2.10.3", "requests": "2.3.0", "requests.packages.chardet": "2.2.1", "requests.packages.urllib3": "dev", "requests.packages.urllib3.packages.six": "1.2.0", "requests.utils": "2.3.0", "simplejson": "3.6.2", "sqlalchemy": "0.9.4", "tarfile": "$Revision: 85213 $", "urllib": "1.17", "urllib2": "2.7", "werkzeug": "0.10.1", "xml.parsers.expat": "$Revision: 17640 $", "xmlrpclib": "1.0.1", "yaml": "3.11", "zlib": "1.0"}}
直接$ docker pull 127.0.0.1:5000/dsds/n24:0.1的结果:
Pulling repository 127.0.0.1:5000/dsds/n24
26d0cf7c402b: Download complete
511136ea3c5a: Download complete
5b12ef8fd570: Download complete
a30bc9f3097e: Download complete
e2cf9c2809f8: Download complete
3a7ab461be7c: Download complete
54c010716757: Download complete
fc53945dff88: Download complete
7ea5303835e2: Download complete
910407b2ccfd: Download complete
32b7defdd54a: Download complete
d89b0238c45f: Download complete
37bc67de5412: Download complete
af3fe4556907: Download complete
ae2614a3432c: Download complete
0b0f23ca58fd: Download complete
f8f5f7f00318: Download complete
a6e7ad544567: Download complete
c8d757458675: Download complete
7d14551b7add: Download complete
1a6e1f078105: Download complete
7fdbd7dd98f6: Download complete
请问这是哪里的问题,谢谢。
我猜可能是版本问题导致的
docker-registry的版本、github.com/fsouza/go-dockerclient(server中使用这个lib库来pullimage的)的版本、docker的版本得匹配才可以
解决了,是agent去pull的,可是我的registry部署在server上,把 127.0.0.1:5000/dsds/n24:0.1改成server_ip:5000/dsds/n24:0.1就好了,谢谢。版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。