-
Notifications
You must be signed in to change notification settings - Fork 785
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
Get default repo tag from docker-archive
#1699
Comments
Thanks for your report. This is working as designed: Skopeo is, mostly, a dumb wrapper around the c/image library, and (Apart from some theoretical cleanliness, this is necessary for such a flexible design: Otherwise, we when adding a new transport, we would have to immediately figure out all the relevant heuristics for all the relevant interactions; if we didn’t do that, any future changes to heuristics would break users.) It is, of course, possible to design any heuristics you like, and implement that either on top of Skopeo or on top of the underling containers/image library. Podman is one tool that has a fairly extensive set of convenient commands and such heuristics. |
I see, ok, well I used the |
True, a Golang application using c/image could do both with a single extraction, via https://github.com/containers/image/blob/44e127c892b7291c66f47b9735ae48a573deadfb/docker/archive/reader.go#L71 . Integrating that into the generic We also tend to discourage using the |
I'm curious; what other format can I use that is compatible with |
That command seems to only consume tar archives, so they are all going to be, at least to an extent, inefficient. In that case, write images to a registry, and pull from a registry instead of importing; even if that meant running a single-purpose registry just for that process. As long as the same compression choices are made, it’s likely to end up being more efficient. |
A friendly reminder that this issue had no activity for 30 days. |
Closing: this is working as currently designed. Alternatively, as far as design goes, it seems reasonable to support Specialized users can write a small wrapper on top of the underlying containers/image library instead of using the generic Skopeo CLI. |
I used
docker save
to create a docker archive.I've noticed that when using
skopeo copy
, it doesn't copy the default tag that's in the archive? My default tag is something likershk0jallj0pnnriby0f1lm022fibglp
, yetskopeo copy
copies it as the latest tag with:skopeo --insecure-policy copy docker-archive:/path/to/archive.tar.gz docker://$CONTAINER_REPOSITORY
On the ECR registry, I see only
latest
tag got updated. This is the same if I useddocker://$CONTAINER_REPOSITORY:latest
.But the archive already has a default tag, as can be seen by:
Is there a way to get skopeo to push using the default tag, the tag that's already in the archive?
Right now I have to fetch the tag out of
skopeo list-tags
or by extracting the output ofdocker load
before being able to use it in theskopeo copy
command.The text was updated successfully, but these errors were encountered: