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

Add multiple Accept headers to Manifest query #191

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cquon
Copy link

@cquon cquon commented Jun 18, 2019

Resolves: #190

Previously:

$ reg manifest alpine
INFO[0000] domain: docker.io
INFO[0000] server address: https://registry-1.docker.io
{
   "schemaVersion": 2,
   "mediaType": "application/vnd.docker.distribution.manifest.v2+json",
   "config": {
     "mediaType": "application/vnd.docker.container.image.v1+json",
     "size": 1512,
     "digest": "sha256:055936d3920576da37aa9bc460d70c5f212028bda1c08c0879aedf03d7a66ea1"
   },
   "layers": [
     {
       "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip",
       "size": 2757034,
       "digest": "sha256:e7c96db7181be991f19a9fb6975cdbbd73c65f4a2681348e63a141a2192a5f10"
     }
   ]
 }

After change:

$ reg manifest alpine
INFO[0000] domain: docker.io
INFO[0000] server address: https://registry-1.docker.io
{
   "manifests": [
     {
       "digest": "sha256:bf1684a6e3676389ec861c602e97f27b03f14178e5bc3f70dce198f9f160cce9",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "amd64",
         "os": "linux"
       },
       "size": 528
     },
     {
       "digest": "sha256:fc6ad107f85e5210d7cbbdb00b6af0b8b1c94a2b0cecc77db19e853b87cd549e",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "arm",
         "os": "linux",
         "variant": "v6"
       },
       "size": 528
     },
     {
       "digest": "sha256:f6d15ec5c7cf08079309c59f59ff1e092eb9a678ab891257b1d2b118e7aecc2b",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "arm",
         "os": "linux",
         "variant": "v7"
       },
       "size": 528
     },
     {
       "digest": "sha256:9d2b3c9ba598ccd7c4aa49e5ad5b4cf47fb882adc3f5955d5e160b07f26a68ee",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "arm64",
         "os": "linux",
         "variant": "v8"
       },
       "size": 528
     },
     {
       "digest": "sha256:1be52adf0390937540f21f66fb8dc4c155b3a0325e380001be08fd5923359e81",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "386",
         "os": "linux"
       },
       "size": 528
     },
     {
       "digest": "sha256:27ca8e336361fa1e0f6efc92f88d3f2a98e0da8ce422bf3230271d576a1f50e7",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "ppc64le",
         "os": "linux"
       },
       "size": 528
     },
     {
       "digest": "sha256:d438d3b6a72b602b70bd259ebfb344e388d8809c5abf691f6de397de8c9e4572",
       "mediaType": "application\/vnd.docker.distribution.manifest.v2+json",
       "platform": {
         "architecture": "s390x",
         "os": "linux"
       },
       "size": 528
     }
   ],
   "mediaType": "application\/vnd.docker.distribution.manifest.list.v2+json",
   "schemaVersion": 2
 }

Signed-off-by: Corey Quon <corey.quon@docker.com>
Copy link

@jose-bigio jose-bigio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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

Successfully merging this pull request may close these issues.

Manifest Lists incorrectly queried from Docker Hub
2 participants