getting to the files system of the Alpine linux wh

2019-05-10 03:40发布

问题:

I am playing with the (awesome) new Docker-for-mac. As I understand it, it runs seamlessly on my mac in an Alpine Linux 'behind the scenes'. Is there a way to ssh into this host so I can see the file system. I want to see the place that docker is storing volume data in /var/lib/docker/....

EDIT: to be clear, it is the host filesystem I want access to, not the containers that run on it. this is the Alpine host

thanks

回答1:

Docker for Mac doesn't use regular tcp networking for ssh, but you can connect to the unix socket on your Mac by using:

screen ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux/tty

and login as root

This seems to be fairly undocumented so YMMV - it worked for me on Version 1.12.0-rc3-beta18 -- it might change in future versions.



标签: docker