How to ssh into docker-machine VirtualBox instance?

You can log into docker-machine hosts by just running

docker-machine ssh default

(Using the "default" host here)

The identity files should be stored under ~/.docker/machine/machines. If you want to log into a container (as opposed to the host), use docker exec as suggested by user2915097.


if you really need to do it via ssh, this is working with docker 1.8.2

init docker:

eval "$(docker-machine env default)"

get the IP from your default docker machine:

docker-machine ip default

this prints something like this out: 192.168.99.100

ssh [email protected]

password is tcuser but you can also use the identity file, see other answer