1
在工作泊坞窗返回代码是不是能够拉动图片:如何搬运工人设法得到的200,而不是401
[b209d3c5] +job pull(ubuntu,)
[debug] registry.go:372 [registry] Calling GET https://index.docker.io/v1/repositories/ubuntu/images
[debug] http.go:160 https://index.docker.io/v1/repositories/ubuntu/images -- HEADERS: map[User-Agent:[docker/1.0.0 go/go1.2.2 git-commit/63fe64c kernel/3.15.1-1-ARCH os/linux arch/amd64]]
[debug] server.go:1182 Retrieving the tag list
[debug] http.go:160 https://cdn-registry-1.docker.io/v1/repositories/library/ubuntu/tags -- HEADERS: map[User-Agent:[docker/1.0.0 go/go1.2.2 git-commit/63fe64c kernel/3.15.1-1-ARCH os/linux arch/amd64]]
[debug] registry.go:327 Got status code 401 from https://cdn-registry-1.docker.io/v1/repositories/library/ubuntu/tags
[error] server.go:1185 Could not reach any registry endpoint
Could not reach any registry endpoint
[b209d3c5] -job pull(ubuntu,) = ERR (1)
如果我尝试手动访问它可靠结果第二URL在401,太。
然而在国内相同的命令还是设法成功地检索标签:
[4e9acee4] +job pull(ubuntu,)
[debug] registry.go:372 [registry] Calling GET https://index.docker.io/v1/repositories/ubuntu/images
[debug] http.go:160 https://index.docker.io/v1/repositories/ubuntu/images -- HEADERS: map[User-Agent:[docker/1.0.0 go/go1.2.2 git-commit/63fe64c kernel/3.14.6-1-ARCH os/linux arch/amd64]]
[debug] server.go:1182 Retrieving the tag list
[debug] http.go:160 https://cdn-registry-1.docker.io/v1/repositories/library/ubuntu/tags -- HEADERS: map[User-Agent:[docker/1.0.0 go/go1.2.2 git-commit/63fe64c kernel/3.14.6-1-ARCH os/linux arch/amd64]]
[debug] registry.go:327 Got status code 200 from https://cdn-registry-1.docker.io/v1/repositories/library/ubuntu/tags
[debug] server.go:1197 Registering tags
[...]
的问题是:这个搬运工实例是怎么得到200结果呢?
是否有检查通信的好方法? (Wireshark可能不如https完全加密。)
可能唯一的办法就是读source code。但我对走的语言不太了解。
你能想到任何更好的解决方案,建立自己的docker并添加一些调试打印?
还有一个[文档】(http://docker.readthedocs.org/en/v0.5.3/api/registry_index_spec/#tags-registry)对于那种REST接口,但它没有指定更多的要求。 – michas