Docker推送错误“被拒绝:请求访问资源被拒绝”

时间:2017-08-15 01:22:35

标签: docker

环境
a)在Hyper V中创建的Cent OS VM b)公司代理背后。

我在使用docker push时遇到了一个奇怪的问题。

我收到以下错误 "拒绝:拒绝请求访问资源"

Docker pull正在运行,没有任何问题。 我附加了在docker push期间生成的守护程序日志。

Aug 15 10:02:40 testmachine dockerd[40449]: time="2017-08-15T10:02:40.886973000+10:00" level=debug msg="Calling GET /_ping"
Aug 15 10:02:40 testmachine dockerd[40449]: time="2017-08-15T10:02:40.887518100+10:00" level=debug msg="Calling GET /v1.27/info"
Aug 15 10:02:40 testmachine dockerd[40449]: time="2017-08-15T10:02:40.893846700+10:00" level=debug msg="Calling POST /v1.27/images/vishnuvpotti/test/push?tag="
Aug 15 10:02:40 testmachine dockerd[40449]: time="2017-08-15T10:02:40.893969800+10:00" level=debug msg="Trying to push docker.io/vishnuvpotti/test to https://registry-1.docker.io v2"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.863929300+10:00" level=debug msg="Pushing repository: vishnuvpotti/test:latest"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.864814900+10:00" level=debug msg="Pushing layer: sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.865066700+10:00" level=debug msg="Pushing layer: sha256:defd90aaa156603d9362f29909f6f5539df841b6398b3836a5d559066295ec2b"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.865155500+10:00" level=debug msg="Pushing layer: sha256:be4ee57de94e9c212ac27cf3b2f7ec826617a622d1e10f5b28558cce1f71ec24"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.865233700+10:00" level=debug msg="Pushing layer: sha256:f971a434fe54442b68fe4d8bb9dc58cc51bfef3d960985fd1d2243a36abe89c2"
Aug 15 10:02:41 testmachine dockerd[40449]: time="2017-08-15T10:02:41.865308500+10:00" level=debug msg="Pushing layer: sha256:68078adbc0cb48954d27352b190afc2b011b3bb3c2adf61c45991669ea02134e"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.691569600+10:00" level=error msg="Upload failed: denied: requested access to the resource is denied"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.691661000+10:00" level=debug msg="Pushing layer: sha256:fb479b796fe5e208adece47fc14092d57c43b1dc0978ddd6a645cbdc7e85bbff"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.694653100+10:00" level=error msg="Upload failed: denied: requested access to the resource is denied"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.694753300+10:00" level=debug msg="Pushing layer: sha256:f32dba9a1eadb592cceb96d7b3fdc4a1c5213044fd7b30ae41e17673ccdf385d"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.694875200+10:00" level=error msg="Attempting next endpoint for push after error: denied: requested access to the resource is denied"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.699788800+10:00" level=debug msg="Pushing layer: sha256:19cbee8a76396ae7b80f835da4be7229dc8b094535ebf50d35ab2bf941039f7a"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.701883600+10:00" level=debug msg="Pushing layer: sha256:5a29dcc5d0b483d880a4736853253433c16103b9e03f9f52e94577cf1895563b"
Aug 15 10:02:43 testmachine dockerd[40449]: time="2017-08-15T10:02:43.707591200+10:00" level=debug msg="Pushing layer: sha256:92f9849bf0840ff917901665d775da4454d84a23439ef2ccbb93c6cc3363ab82"
Aug 15 10:02:44 testmachine dockerd[40449]: time="2017-08-15T10:02:44.588052200+10:00" level=debug msg="Pushing layer: sha256:74351e413c54d36337dff701c3568dc291f45523fe74261281b9ec9372528092"

Docker版本

root@testmachine# docker version
Client:
 Version:      17.03.2-ce
 API version:  1.27
 Go version:   go1.7.5
 Git commit:   f5ec1e2
 Built:        Tue Jun 27 02:21:36 2017
 OS/Arch:      linux/amd64

Server:
 Version:      17.03.2-ce
 API version:  1.27 (minimum version 1.12)
 Go version:   go1.7.5
 Git commit:   f5ec1e2
 Built:        Tue Jun 27 02:21:36 2017
 OS/Arch:      linux/amd64
 Experimental: false

Docker Info

root@testmachine # docker info
Containers: 4
 Running: 1
 Paused: 0
 Stopped: 3
Images: 2
Server Version: 17.03.2-ce
Storage Driver: overlay
 Backing Filesystem: xfs
 Supports d_type: false
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 4ab9917febca54791c5f071a9d1f404867857fcc
runc version: 54296cf40ad8143b62dbcaa1d90e520a2136ddfe
init version: 949e6fa
Security Options:
 seccomp
  Profile: default
Kernel Version: 3.10.0-514.26.2.el7.x86_64
Operating System: CentOS Linux 7 (Core)
OSType: linux
Architecture: x86_64
CPUs: 1
Total Memory: 1.549 GiB
Name: testmachine
ID: ATWM:MTHC:B2BA:6E4E:RAWL:E5VD:OUV2:2QHV:IBVQ:K525:DIPF:ICHC
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 21
 Goroutines: 26
 System Time: 2017-08-15T11:21:02.8957667+10:00
 EventsListeners: 0
Http Proxy: http://proxy
Https Proxy: https://proxy
No Proxy: localhost,127.0.0.1
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

WARNING: overlay: the backing xfs filesystem is formatted without d_type support, which leads to incorrect behavior.
         Reformat the filesystem with ftype=1 to enable d_type support.
         Running without d_type support will not be supported in future releases.

注意:
1)我已在docker hub中检查了我的repo设置,并且Default Repository Visibility是公共的。

2)我删除了〜/ .docker / config.json,重新启动了docker并尝试了。

3)我也尝试过docker login -u myusername

任何人都可以让我知道出了什么问题。这是新的docker版本的问题吗?

更新1:
1)我已将泊坞版更新为最新版本:17.06.0-ce。仍然没有工作。

更新2

2)我在虚拟盒子里创建了一个ubuntu虚拟机,并尝试了最新的docker版本。已安装的ca证书,已编辑的机器和泊坞窗代理信息。仍面临同样的问题。

3)更新3 (16/08/2017) 关闭代理,切换到没有代理的网络,重新启动docker并尝试。还是一样的问题。

4)更新4 (17/08/2017) 我在AWS中创建了一个实例,并且能够推送到docker注册表。所以它必须是企业网络中的一些问题。任何评论都赞赏。

0 个答案:

没有答案