Created
June 19, 2023 17:38
-
-
Save baronfel/addd5f1950ad27eb1977649f3c67abbd to your computer and use it in GitHub Desktop.
HTTP snippet for docker manifest investigations
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@registry = registry-1.docker.io | |
@authEndpoint = auth.docker.io | |
@authService = registry.docker.io | |
@repo = library/ubuntu | |
@tag = jammy | |
# @name authenticate | |
GET https://{{authEndpoint}}/token?service={{authService}}&scope=repository:{{repo}}:pull | |
### | |
@auth = Bearer {{authenticate.response.body.access_token}} | |
# @name getManifestList | |
GET {{registry}}/v2/{{repo}}/manifests/{{tag}} | |
Authorization: {{auth}} | |
Accept: application/vnd.oci.image.index.v1+json | |
### | |
@manifestDigest = {{getManifestList.response.body.manifests[0].digest}} | |
# @name getManifest | |
GET {{registry}}/v2/{{repo}}/manifests/{{manifestDigest}} | |
Authorization: {{auth}} | |
Accept: application/vnd.oci.image.manifest.v1+json | |
### | |
@configDigest = {{getManifest.response.body.config.digest}} | |
# @name getConfig | |
GET {{registry}}/v2/{{repo}}/blobs/{{configDigest}} | |
Authorization: {{auth}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment