到达运行Docker-for-mac的Alpine linux的文件系统 [英] getting to the files system of the Alpine linux which runs Docker-for-mac
问题描述
我正在玩(棒极了)的新的Docker-for-mac。据了解,它可以无缝地运行在我的Mac上,在高山Linux的幕后。有没有办法ssh进入这个主机,所以我可以看到文件系统。我想看到docker正在存储卷数据的地方在/ var / lib / docker /....
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/....
编辑:要清楚,它是主机文件系统我想要访问,而不是运行它的容器。这是高山主持人
to be clear, it is the host filesystem I want access to, not the containers that run on it. this is the Alpine host
谢谢
推荐答案
Mac的Docker不要使用ssh的常规tcp网络,但是您可以通过使用以下方式连接到Mac上的unix套接字:
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
并登录为根
这似乎是相当无证的,所以YMMV - 它在我的版本1.12 .0-rc3-beta18 - 它可能会在将来的版本中更改。
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-for-mac的Alpine linux的文件系统的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!