curl -H "Authorization: Bearer $BEARER" \
-H "Accept: application/vnd.docker.image.manifest.v2+json" \
https://registry-1.docker.io/v2/$NAME/manifests/sha256:3eb57a4024e69d05ace49be70ab9d13610cfe611a0191c7edc26f5a2b675e7b1
Above is the command I use. I've already set the Accept field to be schema version 2 manifest media type in the header but still it returns me manifest with schema version 1
curl is a command line tool and library for transferring data with URLs. curl is used in command lines or scripts to transfer data.
A manifest list is a list of image layers that is created by specifying one or more (ideally more than one) image names. It can then be used in the same way as an image name in docker pull and docker run commands, for example.
The Docker image digest SHA is a critical piece of evidence that makes a container and the content unique. You get the Docker image digest SHA from an image stored in a docker registry. Easy to do if the image has been pulled, just run docker image ls <image> –digests.
The Docker Registry HTTP API is the protocol to facilitate distribution of images to the docker engine. It interacts with instances of the docker registry, which is a service to manage information about docker images and enable their distribution.
I believe the Accept type for a v2 schema is "application/vnd.docker.distribution.manifest.v2+json"
according to the docker registry code, see:
https://github.com/docker/distribution/blob/f4b6fc8d681c42137b7d2bb544b087462bc34d47/manifest/schema2/manifest.go#L15
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With