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

spec: PUT /v2/<name>/manifests/<reference> MUST include Content-Type #477

Conversation

waynr
Copy link
Contributor

@waynr waynr commented Oct 3, 2023

This came up in discussion on the CNCF slack's #distribution channel:

The basic issue is that there is an ambiguity in the spec as-written where it's
not clear what the behavior should be if neither the manifest includes a
mediaType field (since that is optional) nor the PUT request includes a
content-type header.

With this change from SHOULD to MUST it's clearer that registries should
return an error if there is no Content-Type header.

If there are registries out there that don't enforce this and consequently
there are potential clients that don't include it already then it shouldn't be
difficult for those clients to issue a bug fix if they really need to be used
to push to a more strict registry.

@sudo-bmitch
Copy link
Contributor

This needs a signoff to pass the DCO check.

I'm leaning towards approving it, but I'd like to first check if the major registries already require it, or that no major clients are missing the header (the former would be a better check).

@waynr waynr force-pushed the manifest-push-must-include-content-type branch from 40c2157 to 6988fcb Compare October 8, 2023 16:34
Signed-off-by: wayne warren <wayne.warren.s@gmail.com>
@sudo-bmitch
Copy link
Contributor

We brought this up in today's call and it got a NACK from several maintainers. Registries can enforce this since it's a SHOULD today, and clients SHOULD include it and expect errors if they do not.

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.

None yet

2 participants