Copying files from Docker container to host

后端 未结 18 2459
小蘑菇
小蘑菇 2020-11-22 13:39

I\'m thinking of using Docker to build my dependencies on a Continuous Integration (CI) server, so that I don\'t have to install all the runtimes and libraries on the agents

18条回答
  •  北恋
    北恋 (楼主)
    2020-11-22 14:16

    If you don't have a running container, just an image, and assuming you want to copy just a text file, you could do something like this:

    docker run the-image cat path/to/container/file.txt > path/to/host/file.txt
    

提交回复
热议问题