麦克在这里。我通过工具箱安装了 Docker ,所有 Docker 命令都产生了相同的错误:
myuser@mymachine:~/tmp$docker info
Get http:///var/run/docker.sock/v1.20/info: dial unix /var/run/docker.sock: no such file or directory.
* Are you trying to connect to a TLS-enabled daemon without TLS?
myuser@mymachine:~/tmp$sudo docker info
Password:
Get http:///var/run/docker.sock/v1.20/info: dial unix /var/run/docker.sock: no such file or directory.
* Are you trying to connect to a TLS-enabled daemon without TLS?
* Is your docker daemon up and running?
然而,有趣的是:
myuser@mymachine:~/tmp$docker -v
Docker version 1.8.1, build d12ea79
谷歌搜索结果| 此错误表明工具箱未正确安装,需要设置以下环境变量之一(或全部):
DOCKER_HOST
; 和/或DOCKER_CERT_PATH
; 和/或DOCKER_TLS_VERIFY
我已验证DOCKER_HOST
未在我的机器上设置(既不显示env
也不echo $DOCKER_HOST
显示)。所以我的担忧:
- 这些环境变量是什么,它们做什么?他们的正确价值观是什么?
- 如何永久设置它们以使它们保持机器重新启动?
更新
到目前为止运行一个答案建议的命令:
myuser@mymachine:~/tmp$docker-machine start default
Error: Host does not exist: default
myuser@mymachine:~/tmp$eval $(docker-machine env default)
Error: Host does not exist: default
想法?