How to access an docker's container file syste

2019-08-03 17:39发布

问题:

I need to access the file system of a non-running docker's container. What is the best way to accomplish that?

Thanks,

回答1:

The docker export command is what you are after. It will print on the standard output the content of a container filesystem as a tar archive.

docker export <container_name> > my_container.tar

or

docker export --output="my_container.tar" <container_name>


标签: docker