Add container copy/cp command for host-container file transfer#1190
Conversation
|
Related to #232 |
|
⏺ Scenario 1:
Scenario 2:
Scenario 3:
Scenario 4:
|
|
Hi @simone-panico The bold italic phrases are what is different from desired behavior (i.e., docker) now, and can be addressed. Below is general comments.
|
|
Hi @simone-panico You may need to build this project with local containerization (BUILDING.md), and wire up |
|
@JaewonHur the change above does not allow copying directories. It adds a tar reader/writer that will be used to support this, but it's not in the change itself. |
|
If you’re interested, I could try to create a Directory Copier within |
|
Hey @JaewonHur |
|
@simone-panico Thank you! |
|
Hey @JaewonHur, sorry this took so long. I had to finish my finals. |
|
@simone-panico Not at all :) I really appreciate for all your hard work! |
|
@simone-panico Could you do Once the containerization PR is merged, we should bump that in Package.swift, and able to merge this PR. |
Should be correct now, right? |
|
Yes. Looks good. |
Code Coverage
|
This pull request enhances the handling of file and directory copy operations in Linux containers, particularly by improving destination path resolution and error handling for the `copyIn` operation with the `Stat RPC` This PR is needed for [container#1190](apple/container#1190)
|
Hi! I tagged latest containerization to Here could you update The |
|
@simone-panico Finally merged :) Thank you so much for your hard work and patience! |
|
@simone-panico Definitely, thanks for the patience and the effort you've put in. It's nice to have this feature in place! |
Type of Change
Motivation and Context
Closes #232.
Adds the
container copy(aliased ascp) command to copy files between a running container and the local filesystem.I saw #1023 and the feedback from @dcantah — the previous attempt relied on tar being installed inside the container.
This implementation takes the recommended approach:
file transfers go through the guest agent via the existing
copyIn/copyOutmethods on the coreContainerization, with no dependency on container tooling.Testing