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
c8d/pull: Support legacy schema1 prettyjws manifests #46513
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well that was easy
300fd48
to
01f599e
Compare
Makes it possible to pull `application/vnd.docker.distribution.manifest.v1+prettyjws` legacy manifests. They are not stored in their original form but are converted to the OCI manifests. Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
01f599e
to
68b67b3
Compare
@@ -104,6 +104,10 @@ func (i *ImageService) PullImage(ctx context.Context, image, tagOrDigest string, | |||
infoHandler := snapshotters.AppendInfoHandlerWrapper(ref.String()) | |||
opts = append(opts, containerd.WithImageHandlerWrapper(infoHandler)) | |||
|
|||
// Allow pulling application/vnd.docker.distribution.manifest.v1+prettyjws images | |||
// by converting them to OCI manifests. | |||
opts = append(opts, containerd.WithSchema1Conversion) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you know if we can detect these in this flow, and print a deprecation warning? (see #46137)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could print that deprecation in one of the image handlers maybe? That's if the manifest is not already converted once it gets to the handler
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we can! I somehow missed the deprecation warning when looking at the non-c8d output 😄
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Makes it possible to pull
application/vnd.docker.distribution.manifest.v1+prettyjws
legacy manifests.They are not stored in their original form but are converted to the OCI manifests.
- How to verify it
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)