Skip to content

Outline the transportable objects #23

Closed

Description

@vbatts

From a single tar archive of tar archives and JSON documents, or a manifest JSON document that points to other objects needing to be fetched.

UserStory:

  • As an opensource project, I want to produce an OCI image for the world to consume.

See also https://groups.google.com/a/opencontainers.org/d/msg/dev/VKpZNs-qYoI/RzPhj71ODgAJ

Activity

  1. jonboulle commented on Apr 15, 2016

    @jonboulle
    Contributor

    Is this essentially the enhancement/replacement of serialization.md?

  2. vbatts commented on Apr 15, 2016

    @vbatts
    MemberAuthor

    @jonboulle sorry, this was more of placeholder thought. The serialization doc does have tar archive info. Though I was thinking more of the manifest. This may be a non-topic, if the culmination of referenced layers in a manifest are handled independently, but the docs need to be cleaned up to show the transportable states of the image.

  3. changed the title [-]Define the portable archive[/-] [+]Organize docs to easily see the transportable objects[/+] on Apr 15, 2016
  4. vbatts commented on Apr 15, 2016

    @vbatts
    MemberAuthor

    Updated the title and comment. Hopefully that helps a bit more.

  5. changed the title [-]Organize docs to easily see the transportable objects[/-] [+]Outline the transportable objects[/+] on Apr 18, 2016
  6. vbatts commented on Apr 20, 2016

    @vbatts
    MemberAuthor

    Once you've gotten all the objects on disk specified in a manifest, there will be a validation and translation to the runtime-spec bundle, or similar. This needs to be outlined as well.

  7. philips commented on Apr 20, 2016

    @philips
    Contributor

    I think there are two things here.

    Spec out a directory layout for manifests and blobs that mirrors how the image manifests work. My suggestion is that the manifest is the primary object in the system so the other "things" are adjacent.

    $ cd my-oci-image/
    $ find .
    .
    ./blobs
    ./blobs/sha256:5b0bcabd1ed22e9fb1310cf6c2dec7cdef19f0ad69efa1f392e94a4333501270
    ./blobs/sha256:e692418e4cbaf90ca69d05a66403747baa33ee08806650b51fab815ad7fc331f
    ./manifests
    ./manifests/v1.0
    ./manifests/v1.0-debug
    

    Build a tool that consumes this directory and creates a runnable OCI bundle.

    ocitool runtime-bundle file:///path/to/my-oci-image/manifests/v1.0
    
  8. self-assigned this
    on Apr 20, 2016
  9. wking commented on Apr 20, 2016

    @wking
    Contributor

    On Wed, Apr 20, 2016 at 03:20:44PM -0700, Brandon Philips wrote:

    $ find .
    .
    ./blobs
    ./blobs/sha256:5b0bcabd1ed22e9fb1310cf6c2dec7cdef19f0ad69efa1f392e94a4333501270
    ./blobs/sha256:e692418e4cbaf90ca69d05a66403747baa33ee08806650b51fab815ad7fc331f
    ./manifests
    ./manifests/v1.0
    ./manifests/v1.0-debug

    I'd expect the format should also include signatures and the name ↔
    format://manifest-hash being asserted by those signatures, because the
    “I just want to attach one thing” workflow 1 shouldn't require
    additional network activity to collect those names and signatures.

    And the single-archive-tar use-case needs a HEAD reference or some
    such to pick the default manifest.

    So how about:

    ./VERSION
    ./HEAD
    ./objects/sha256/5b0bcabd1ed22e9fb1310cf6c2dec7cdef19f0ad69efa1f392e94a4333501270
    ./objects/sha256/e692418e4cbaf90ca69d05a66403747baa33ee08806650b51fab815ad7fc331f
    ./objects/sha256/ca6e91e8f982603d5ee741db911fdd8814185f4da52df3dba9e90cf67aed9c9a
    ./objects/sha256/fada3467c61b55140ce331f4f515fe61d1d1b99951893aee822c7c3c394061f6
    ./objects/sha256/07dec7175b024a30f22b1be7853480472b9b406afc593568b6f19dd7bf08f507
    ./objects/sha256/19f58930b0fffd0dd3e4ed7a4a4059f45fed9a759f69f8544a45ac0dfd954b36
    ./objects/sha256/6ce50f12c5a18c8c755d05c9f760ae0d0f71f60885b8937b94a1da52fc9b2898
    ./objects/sha256/d1ee7338f8ebdcaf78acbd63e640cfd9e1a45a29d23c63656d3158c350c3325d
    ./manifests/v8.0
    ./manifests/v8.0-debug

    where:

    • VERSION contains ‘application/vnd.oci.image.v1.0’ or some such.

    • sha256:5b0b… and sha256:e692… are layer tarballs (or some other
      resource referenced from the manifest).

    • sha256:ca6e… and sha256:fada… are manifests.

    • sha256:07d3… and sha256:19f5… are JSON like TUF's METAFILES 2,
      with an external METAPATH moving to an internal ‘name’:

      {
      "name": "debian 8.0",
      "hashes" : {
      "sha256": "ca6e91e8f982603d5ee741db911fdd8814185f4da52df3dba9e90cf67aed9c9a",
      "sha512": "2c9af2165c9555329e07a3d88d366f7e58767a9067d206022de107ff91426248bf6404aead451c9106df809289c46ea55d2250600c004a4f4dbf97d7648f8fa2",
      "ipfs": "QmVc6zuAneKJzicnJpfrqCH9gSy6bz54JhcypfJYhGUFQu",
      …
      ],
      "custom": …,
      }

      to associate a name and/or custom metadata with a given manifest (in
      its various hashes).

    • sha256:6ce5… and sha256:d1ee… are detached signatures for the
      metafile blobs.

    • The optional manifests/* contain payloads like:

      {
      "signed": "sha256/07dec7175b024a30f22b1be7853480472b9b406afc593568b6f19dd7bf08f507",
      "signatures": [
      "sha256/6ce50f12c5a18c8c755d05c9f760ae0d0f71f60885b8937b94a1da52fc9b2898",
      "sha256/d1ee7338f8ebdcaf78acbd63e640cfd9e1a45a29d23c63656d3158c350c3325d"
      ]
      }

    • The optional HEAD contains ‘manifests/v8.0’ or some other path to
      the default metafile.

    And folks who wanted could hit a signature registry to check for
    additional signatures (or revocations) for sha256/07de… etc.

    Taking this to its logical conclusion, you might also want to also
    include blobs for and references to public keys 3, signing
    algorithms 4, validity schemes 5, etc. It just depends on how
    much of the verification workflow you want to be able to preform based
    on the file contents vs. alternative communication channels and how
    much you like linked data ;).

  10. philips commented on Apr 20, 2016

    @philips
    Contributor

    VERSION doesn't seem necessary. The manifests describe themselves.

  11. philips commented on Apr 20, 2016

    @philips
    Contributor

    I am sort of "meh" on creating some optimization that doesn't force a user to specify exactly what they want. HEAD and "latest" create all sorts of weird races and UX.

  12. wking commented on Apr 21, 2016

    @wking
    Contributor
  13. 18 remaining items

  14. vbatts commented on May 2, 2016

    @vbatts
    MemberAuthor

    @philips Sorry for now being clear. I was thinking that ./manifests/0.8.0 or ./refs/0.8.0 file just had a sha256:deadbeef.. contents. Where that referenced object is the JSON document.

  15. added this to the v1.0.0 milestone on May 24, 2016
  16. stevvooe commented on May 24, 2016

    @stevvooe
    Contributor

    @vbatts @philips @wking Given the confusion between #23 and #38, I'm wondering if this issue should be more oriented towards collecting the system objects into a specification, called out by mediatype.

  17. wking commented on May 24, 2016

    @wking
    Contributor

    On Tue, May 24, 2016 at 04:21:38PM -0700, Stephen Day wrote:

    I'm wondering if this issue should be more oriented towards
    collecting the system objects into a specification, called out by
    mediatype.

    That sounds useful to me. Are you suggesting specifying things like:

    • application/vnd.oci.image.name.v1+json
    • application/vnd.oci.signature.v1+json
    • application/vnd.oci.signature.list.v1+json

    I have suggestions for the first and last of those sketched in 1.

    And I'd suggest listing existing MIME types
    (e.g. application/pgp-signature 2, application/jose+json 3) that
    implementations are likely to support. Rolling our own signature MIME
    types doesn't seem useful.

  18. stevvooe commented on May 25, 2016

    @stevvooe
    Contributor

    @wking While I wasn't really thinking of signatures here, that is definitely a use case.

    The advantage is that no one needs to add a new way to add signatures to the archive format. We simply specify the mediatype and parentage (how it is referenced) and it can be picked up as a content addressable blob in the archive.

    Rolling your own mediatypes may be useful, but can be ignore. Refs are only followed if the component understands the mediatype:

    refs/0.8.0
        /signatures -> {"digest": <sha to signature file>, "mediatype": "application/some-signature-extension"} 
    
  19. wking commented on May 25, 2016

    @wking
    Contributor

    On Tue, May 24, 2016 at 07:38:09PM -0700, Stephen Day wrote:

    The advantage is that no one needs to add a new way to add
    signatures to the archive format. We simply specify the mediatype
    and parentage (how it is referenced) and it can be picked up as a
    content addressable blob in the archive.

    I think specifying “how it is referenced” is adding signatures to
    the archive format. But I agree that runtimes won't need to support
    all possible signature types.

  20. philips commented on May 27, 2016

    @philips
    Contributor

    Everyone- I put up a PR to define an "image layout": #94

  21. vbatts commented on Jul 27, 2016

    @vbatts
    MemberAuthor

    This is fixed by #94 IMO

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions