运行docker在docker quickstart终端中运行hello-world时来自守护程序的错误响应“ proxyconnect tcp:EOF”

时间:2019-06-27 09:27:29

标签: docker windows-10 docker-toolbox docker-quickstart-terminal

我在公司代理后面的Windows版本10.0.15063上运行docker工具箱,当我运行命令docker run hello-world

时遇到以下错误
Unable to find image 'hello-world:latest' locally
C:\Program Files\Docker Toolbox\docker.exe: Error response from daemon: Get https://registry-1.docker.io/v2/: proxyconnect tcp: EOF.
See 'C:\Program Files\Docker Toolbox\docker.exe run --help'

在尝试使用docker login登录到docker时遇到相同的错误。 我已经尝试在/ Docker Toolbox / start.sh中导出HTTPS_PROXY和HTTP_PROXY并将其添加到我的环境变量中,但是这些方法似乎都不起作用。

这是我的docker info

$ docker info
Containers: 0
 Running: 0
 Paused: 0
 Stopped: 0
Images: 0
Server Version: 18.09.6
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: bb71b10fd8f58240ca47fbb579b9d1028eea7c84
runc version: 2b18fe1d885ee5083ef9f0838fee39b62d653e30
init version: fec3683
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.14.116-boot2docker
Operating System: Boot2Docker 18.09.6 (TCL 8.2.1)
OSType: linux
Architecture: x86_64
CPUs: 1
Total Memory: 989.4MiB
Name: default
ID: PNCR:EWZF:D4O3:7KDP:UW7W:4NEO:YGTT:CHWV:VF5U:YTE6:GD66:WKHS
Docker Root Dir: /mnt/sda1/var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
HTTP Proxy: http://xxxx:xxxx
HTTPS Proxy: https://xxxxx:xxxx
No Proxy: 192.168.99.100
Registry: https://index.docker.io/v1/
Labels:
 provider=virtualbox
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

这是我进入默认计算机并运行sudo vi /var/lib/boot2docker/profile

的内容
CACERT=/var/lib/boot2docker/ca.pem
DOCKER_HOST='-H tcp://0.0.0.0:2376'                                                                             
DOCKER_STORAGE=aufs                                                                                                                                     
DOCKER_TLS=auto                                                                                                                                      
SERVERKEY=/var/lib/boot2docker/server-key.pem                                                                                                               
SERVERCERT=/var/lib/boot2docker/server.pem                                                                                                                                                                                                                                                                               
export "HTTP_PROXY=http://proxy2:8080"                                                                                                                      
export "HTTPS_PROXY=https://proxy2:8080"                                                                                                                    
export "NO_PROXY=192.168.99.100"

我想念什么吗?过去的一个小时我一直在努力,没有任何运气。

1 个答案:

答案 0 :(得分:0)

我实际上知道了。 最初,我在使用公司网络时,网络团队已将每个IP列入黑名单,然后将受信任的IP列入白名单。这就是导致尝试连接到外部注册表时整个问题的原因。

这些是我要解决的步骤:

  1. 我切换到个人网络,然后禁用了代理,即。在 Internet属性> 切换到自动配置> 自动检测设置。

  2. 从C:\ Program Files \ Docker Toolbox中的start.sh中删除了HTTP_PROXY和HTTPS_PROXY导出

  3. 打开Windows 防火墙>高级设置>入站规则>添加新规则;然后 创建了一个IP范围为1-100的自定义规则,然后将其命名为Docker。

  4. C:\ Users \ myusername *

  5. 中删除 .Virtualbox 文件夹
  6. 重新启动Docker Quickstart Terminal。它创建了一个新的默认docker-machine并更新了配置设置,现在可以从外部注册表中提取图像了。

相关问题