创建新通用 docker 机器时出错
Error on create new generic docker machine
我试图在 VPS 上使用驱动程序 "generic" 创建新的 docker-机器,但出现此错误:
MacBook-Pro-Pavel:demo pavel$ docker-machine create --driver generic --generic-ssh-key ~/.ssh/id_rsa --generic-ip-address=5.63.154.209 regru
Running pre-create checks...
Creating machine...
(regru) Importing SSH key...
Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...
Detecting the provisioner...
Provisioning with debian...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...
Error creating machine: Error running provisioning: ssh command error:
command : sudo systemctl -f start docker
err : exit status 1
output : Job for docker.service failed. See 'systemctl status docker.service' and 'journalctl -xn' for details.
带驱动的机器"virtualbox"正常创建:
MacBook-Pro-Pavel:~ pavel$ docker-machine ls
NAME ACTIVE DRIVER STATE URL SWARM DOCKER ERRORS
regru - generic Running tcp://5.63.154.209:2376 Unknown Unable to query docker version: Cannot connect to the docker engine endpoint
swarm-node-0 - virtualbox Running tcp://192.168.99.100:2376 v17.06.0-ce
swarm-node-1 - virtualbox Running tcp://192.168.99.101:2376 v17.06.0-ce
systemctl status docker.service
è journalctl -xn
here.
我做错了什么?
更新
$ docker version
Client:
Version: 17.06.0-ce
API version: 1.30
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:31:53 2017
OS/Arch: darwin/amd64
Server:
Version: 17.06.0-ce
API version: 1.30 (minimum version 1.12)
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:51:55 2017
OS/Arch: linux/amd64
Experimental: true
很有可能,您做的每件事都是正确的。
docker 似乎有问题。
我不太了解,但是这里有一个 link 的详细信息:
https://forums.docker.com/t/docker-machine-create-fails-on-digitalocean/34750
解决方法是手动提供较旧的 docker 引擎:
docker-machine create
--driver amazonec2
--engine-install-url=https://web.archive.org/web/20170623081500/https://get.docker.com
将 --engine-install-url 添加到您的设置中,看看是否有效。
我试图在 VPS 上使用驱动程序 "generic" 创建新的 docker-机器,但出现此错误:
MacBook-Pro-Pavel:demo pavel$ docker-machine create --driver generic --generic-ssh-key ~/.ssh/id_rsa --generic-ip-address=5.63.154.209 regru
Running pre-create checks...
Creating machine...
(regru) Importing SSH key...
Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...
Detecting the provisioner...
Provisioning with debian...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...
Error creating machine: Error running provisioning: ssh command error:
command : sudo systemctl -f start docker
err : exit status 1
output : Job for docker.service failed. See 'systemctl status docker.service' and 'journalctl -xn' for details.
带驱动的机器"virtualbox"正常创建:
MacBook-Pro-Pavel:~ pavel$ docker-machine ls
NAME ACTIVE DRIVER STATE URL SWARM DOCKER ERRORS
regru - generic Running tcp://5.63.154.209:2376 Unknown Unable to query docker version: Cannot connect to the docker engine endpoint
swarm-node-0 - virtualbox Running tcp://192.168.99.100:2376 v17.06.0-ce
swarm-node-1 - virtualbox Running tcp://192.168.99.101:2376 v17.06.0-ce
systemctl status docker.service
è journalctl -xn
here.
我做错了什么?
更新
$ docker version
Client:
Version: 17.06.0-ce
API version: 1.30
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:31:53 2017
OS/Arch: darwin/amd64
Server:
Version: 17.06.0-ce
API version: 1.30 (minimum version 1.12)
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:51:55 2017
OS/Arch: linux/amd64
Experimental: true
很有可能,您做的每件事都是正确的。 docker 似乎有问题。 我不太了解,但是这里有一个 link 的详细信息: https://forums.docker.com/t/docker-machine-create-fails-on-digitalocean/34750
解决方法是手动提供较旧的 docker 引擎:
docker-machine create
--driver amazonec2
--engine-install-url=https://web.archive.org/web/20170623081500/https://get.docker.com
将 --engine-install-url 添加到您的设置中,看看是否有效。