3

Is there a way to copy file from docker container to the host by running the command on the container itself? I know that I can use "volume" but it will not work - I want to copy files from container to arbitrary places on the host. Only SCP file vis SSH?

Trav Erse
  • 191
  • 2
  • 3
  • 12
  • 1
    Possible duplicate of [Copying files from Docker container to host](https://stackoverflow.com/questions/22049212/copying-files-from-docker-container-to-host) – David Maze Feb 06 '19 at 14:10

1 Answers1

0

From: Copying files from Docker container to host you can run:

docker cp <containerId>:/file/path/within/container /host/path/target
Nic
  • 327
  • 1
  • 18