Skip to content

Conversation

@wking
Copy link
Contributor

@wking wking commented Nov 16, 2016

The previous wording (“has” and “contains”) was not clear enough to avoid confusion. I consider this PR to be a spec clarification, and not a spec change, but others will probably disagree (which is why I think we need the clarification).

If you cared about running images from the layout, you'd need “and there MUST be at least one unpackable ref” language. And then you have to match the oci-layout version with the media types that were unpackable when it was current (or is validity in the eye of the validator?)… This is a bowl that I do not want to fathom ;).

Maybe folks are just using an image-layout to ship some missing blobs (and have refs empty). I don't see any incentive to image-authors to publish ref-less blobs and then pretend they are runnable, so I don't see a need to get into the business of restricting refs.

Or maybe they're shipping some missing refs (and have blobs empty). Maybe they expect all blobs to be fetched via the descriptor's urls. Those sound fine to me too, so I don't think we should be in the business of restricting blobs (and we already have “The blobs directory MAY be missing referenced blobs…”).

I am fine with validation code warning users about either case (e.g. “this image-layout has no refs” or “refs a, b, and c require blobs which are not stored in this image-layout”), but I don't think the spec should block either of those.

Ping @q384566678 and @xiekeyang (for opencontainers/image-tools#83) and @runcom (for #287).

The previous wording ("has" and "contains") was not clear enough to
avoid confusion [1].  I consider this PR to be a spec clarification,
and not a spec change, but others will probably disagree [2] (which is
why I think we need the clarification).

If you cared about running images from the layout, you'd need "and
there MUST be at least one unpackable ref" language.  And then you
have to match the oci-layout version with the media types that were
unpackable when it was current (or is validity in the eye of the
validator?)... This is a bowl that I do not want to fathom ;).

Maybe folks are just using an image-layout to ship some missing blobs
(and have refs empty).  I don't see any incentive to image-authors to
publish ref-less blobs and then pretend they are runnable, so I don't
see a need to get into the business of restricting refs.

Or maybe they're shipping some missing refs (and have blobs empty).
Maybe they expect all blobs to be fetched via the descriptor's 'urls'.
Those sound fine to me too, so I don't think we should be in the
business of restricting blobs (and we already have "The blobs
directory MAY be missing referenced blobs...").

I am fine with validation code *warning* users about either case
(e.g. "this image-layout has no refs" or "refs a, b, and c require
blobs which are not stored in this image-layout"), but I don't think
the spec should block either of those.

[1]: opencontainers#287
[2]: opencontainers/image-tools#83 (comment)

Signed-off-by: W. Trevor King <[email protected]>
@philips
Copy link
Contributor

philips commented Nov 16, 2016

LGTM

Approved with PullApprove

1 similar comment
@stevvooe
Copy link
Contributor

stevvooe commented Nov 16, 2016

LGTM

Approved with PullApprove

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.

3 participants