Skip to content

Variadic docker cp command #50463

Open

Description

@alexandredoyen29

Description

Hi everyone,

Thank you for your work around Moby !
I would like to suggest you an improvement for the docker cp command :
In fact, to copy multiple files, we have to run successively multiple times the docker cp command, because it takes only 2 arguments.

The idea of this feature request is to have a variadic docker cp that can take multiple files, and place them in a container in a specific path.
For example, docker cp toto titi tutu my_awesome_container:/root/ will copy toto, titi and tutu under /root/ of the my_awesome_container, like the behavior of the Linux's cp command.

Best regards,

Activity

  1. added
    kind/featureFunctionality or other elements that the project doesn't currently have. Features are new and shiny
    on Jul 21, 2025
  2. alexandredoyen29 commented on Jul 21, 2025

    @alexandredoyen29
    Author

    In addition, by design, this will permit to use bash jokers to copy multiple files : docker cp t* => docker cp toto titi tutu => root@my_awesome_container# ls => toto titi tutu.

  3. jasonoh11 commented on Nov 11, 2025

    @jasonoh11

    Hello, I'm interested in contributing and would like to work on this feature if it's available.

    My classmate Ian Kim and I are CS students at the University of Texas, currently taking a virtualization course that includes an open-source contribution component.

    We proposed this issue to our professor, and he approved it as a suitable contribution. Could you confirm whether this is something the team is interested in moving forward with? If so, could it be assigned to me?

    Thanks!

  4. thompson-shaun commented on Nov 12, 2025

    @thompson-shaun
    Contributor

    Thanks for your interest @jasonoh11! Let's see what some of the team thinks :)

    @vvoland @thaJeztah

  5. jasonoh11 commented on Nov 13, 2025

    @jasonoh11

    Thanks, any updates on this?

  6. jasonoh11 commented on Nov 24, 2025

    @jasonoh11

    We've begun researching some of the code for this issue, is this something the maintainers are interested in pursuing? Just checking before we fully dive in, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/featureFunctionality or other elements that the project doesn't currently have. Features are new and shinystatus/0-triage

    Projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions