~/.ssh/my_id_rsa
in a VM created by docker-machine create
gets disappeared whenever I restart it. I've read documents on docs.docker.com, but I couldn't find information about this issue.
My host machine is Mac (El Capitan), and the version of docker-machine is as follows:
$ docker-machine version
docker-machine version 0.6.0, build e27fb87
I've created my VM with following options:
$ docker-machine create --driver virtualbox dev
Is there any advice on how to fix this issue? Where should I look into?
More concretely, I want to know how to avoid this issue:
(host) $ docker-machine create --driver virtualbox dev
(host) $ docker-machine ssh dev
(dev) $ ssh-keygen
...
(dev) $ ls ~/.ssh
authorized_keys authorized_keys2 id_rsa id_rsa.pub
(dev) $ logout
(host) $ docker-machine restart dev
(host) $ docker-machine ssh dev
(dev) $ ls ~/.ssh
authorized_keys authorized_keys2
Where's "id_rsa" and "id_rsa.pub"?