企业代理背后的docker-machine

企业代理背后的docker-machine

我已经安装了 Machine(Docker 工具),我正在尝试按照用户指南学习如何使用它。我正在运行 centOS 6.6

由于我在公司代理后面工作,因此我导出了一些环境变量以使事情正常运行:

#!/bin/bash

http_proxy='http://<domain>\\<login>:<password>@<proxy>:<port>'
https_proxy='https://<domain>\\<login>:<password>@<proxy>:<port>'
export http_proxy https_proxy

当我想创建一台机器时,我的问题就出现了。例如,我正在使用 VirtualBox(我也安装了它)对其进行测试:

sudo -E docker-machine create --driver virtualbox dev

我使用 -E 选项来防止 sudo 丢弃环境变量。我认为问题不在于这 2 条代理线路,因为我在其他一些情况下也使用过它们,而且它们运行正常(例如:从 Docker hub 下载镜像、使用 cURL 下载文件、安装 pip 包等)。

该命令行的输出:

WARN[0005] Unable to check for the latest release: Get https://api.github.com/repos/boot2docker/boot2docker/releases: dial tcp 192.30.252.136:443: i/o timeout
INFO[0005] Downloading boot2docker.iso to /root/.docker/machine/cache/boot2docker.iso...
ERRO[0005] Error creating machine: Get : unsupported protocol scheme ""
WARN[0005] You will want to check the provider to make sure the machine and associated resources were properly removed.
FATA[0005] Error creating machine

显然其他人也遇到过类似的问题,而且似乎已经解决了:https://github.com/docker/machine/pull/625

我可能做错了什么,但我真的不明白,而且通过谷歌搜索也找不到很多帮助。

相关内容