Closed waynr closed 4 months ago
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).
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.
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 acontent-type
header.With this change from
SHOULD
toMUST
it's clearer that registries should return an error if there is noContent-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.