none
Is it possible to copy files from/to windows docker container/windows server 2016 Host... RRS feed

  • Question

  • Hi,

    i am unable to copy files from Windows Server 2016 Host Machine to WindowsServerCore Docker Container.

    Is there any way to do..

    Thanks

    Sujay

    Wednesday, October 19, 2016 11:36 AM

All replies

  • You can do in multiple ways.

    1. Map host volume to container.

    For ex: docker run -it --volume=c:\host:c:\container windowsservercore cmd

    In above case all the files which you put on host folder c:\host will be visible inside under container folder and vice versa.

    2. You can use docker cp command to copy files from host machine to WindowsServerCore Docker.

        But currently it only works for Windowsserver container and not with Hyper-V container.

    • Proposed as answer by Rohit Jaini Wednesday, October 19, 2016 5:53 PM
    Wednesday, October 19, 2016 5:53 PM