繁体   English   中英

boot2docker - 运行docker version命令时尝试连接时发生错误

[英]boot2docker - An error occurred trying to connect when running docker version command

当我使用boot2docker启动boot2docker-vm时,然后在gitbash中运行docker version命令我得到以下内容:

$ docker version
Client version: 1.6.2
Client API version: 1.18
Go version (client): go1.4.2
Git commit (client): 7c8fca2
OS/Arch (client): windows/amd64
FATA[0021] An error occurred trying to connect: Get     https://192.168.59.103:2376/v1.18/version: dial tcp 192.168.59.103:2376: ConnectEx tcp: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

但是当我进入虚拟盒时,我看到boot2docker-vm正在运行。 当我停止boot2docker-vm,然后自己启动它 - 我可以使用vm来使用docker - 使用gitbash更容易使用它...任何人都有任何想法?

你必须在gitbash中初始化shell,使用:

$ $(boot2docker shellinit) 

在终端。

以下是mac的文档: https//docs.docker.com/installation/mac/

博客文章描述了boot2docker安装后VirtualBox for Win64系统的配置。

  1. 更改VirtualBox全局设置以在网络适配器#2而不是#3上提供DHCP服务器,其设置与#3完全相同
  2. 将主机专用网络适配器的boot2docker-vm网络配置从预配置的适配器#3更改为#2

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM