Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

proposal: Support append images into docker archive #2231

Closed
STARRY-S opened this issue Dec 28, 2023 · 1 comment
Closed

proposal: Support append images into docker archive #2231

STARRY-S opened this issue Dec 28, 2023 · 1 comment

Comments

@STARRY-S
Copy link

Currently, skopeo does not support appending images to the existing docker archive:

$ skopeo copy docker://alpine:3.2 docker-archive:./test.tar
FATA[0000] initializing destination docker-archive:./test.tar: docker-archive doesn't support modifying existing images

Can we add appending new images to the existing docker archive file support?
Related code position: https://github.com/containers/image/blob/main/docker/archive/writer.go#L52

@mtrmac
Copy link
Collaborator

mtrmac commented Jan 2, 2024

For the record, there is no way to do that by “appending”, because a tar file ends with and “end of file” marker. There is also a “manifest” file in the tar archive, which would need to be replaced. So we are looking at a complete copy+rewrite of the tar file to add a new image.

As always, consider docker-archive: a compatiblity/interoperability mechanism, it’s way too inefficient to be a part of any other workflows, and a registry server should be used instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants