0

I have a MacMini that is sitting in the server room which has a docker for mac running on it. I'm able to use docker directly on the machine when I ssh in just fine.

$ docker --version                                                                                                  
Docker version 19.03.5, build 633a0ea

But I would like to connect to the mac minis docker engine from my own computer using docker-machine. I have tried the following command to create the docker-machine.

docker-machine create -d generic \
--generic-ip-address 10.0.0.0 \
--generic-ssh-key ~/.ssh/mysshkey \
--generic-ssh-user myusername \
--generic-ssh-port 22 \
macmini

Error Messages:

Running pre-create checks...
Creating machine...
(macmini) 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...
Error creating machine: Error detecting OS: Error getting SSH command: ssh command error:
command : cat /etc/os-release
err     : exit status 1
output  : cat: /etc/os-release: No such file or directory

Has anyone been able to connect remotely to docker-engine running MacOS Catalina using docker-machine? Any tips or pointers would be appreciated. Thank you!

whobutsb
  • 249
  • 2
  • 3
  • 6

1 Answers1

0

It's not possible. Docker for Mac can't accept incoming connections.

from https://docs.docker.com/docker-for-mac/networking/#i-cannot-ping-my-containers

I cannot ping my containers

Docker Desktop for Mac can’t route traffic to containers.

aerickson
  • 9
  • 2