Skip to content

Remove dependency on the docker_content_digest header #98

@yeikel

Description

@yeikel

This is a follow up for #90 and #83

The spec is clear about these headers :

From : https://github.com/opencontainers/distribution-spec/blob/6bc87156eacf3b73362db343eb6b63d7abeedf7e/spec.md?plain=1#L51-L52

Because of the origins this specification, the client MAY encounter Docker-specific headers, such as Docker-Content-Digest, or Docker-Distribution-API-Version. These headers are OPTIONAL and clients SHOULD NOT depend on them.

Currently, we have usages of this header in at least two places :

dohead(tag_path).headers[:docker_content_digest]

doget(tag_path).headers[:docker_content_digest]

My environment is one example implementation where this header is not present at all, and as stated above, that falls within the spec. We should either :

  1. Have a fallback mechanism for environments where this header is not present
  2. Follow the advise shared above and remove this dependency as quoted "These headers are OPTIONAL and clients SHOULD NOT depend on them"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions