Getting runc config.json from docker container

醉酒当歌 提交于 2019-12-11 17:55:36

问题


I am trying to create a runc container from a docker container.

I followed this blog post and was successfull in extracting the config.json from the running docker container.

The issue is that

  1. The path where I found the config.json was different then the references I found online
  2. The same path does not work on a different host which has, as far as I can tell, the same docker version. On that host, I have not been able to find where the config.json is generated.

I have conflicting information on where to find the config.json, and am unable to find it on my host.

|config.json location                     | source                         |
|-----------------------------------------|--------------------------------------------|
|/run/docker/libcontainerd/<container id> | http://crunchtools.com/getting-ninja-runc/ |
|/var/run/docker/libcontainerd/<container id> |https://github.com/genuinetools/riddler |
|/var/run/docker/containerd/daemon/io.containerd.runtime.v1.linux/moby/<container id> | my host #1 |
| ??? | my host #2 |

What other locations can I check, and how can I tell which one it will be? Is this configured somewhere, does this depend on the version of docker, containerd, runc, or something else?

来源:https://stackoverflow.com/questions/54303822/getting-runc-config-json-from-docker-container

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!