Code Monkey home page Code Monkey logo

Comments (13)

vsoch avatar vsoch commented on June 9, 2024 2

Which btw, would have been totally okay too. :)

from artifacts.

stevvooe avatar stevvooe commented on June 9, 2024 1

I think this encodes what we intend. At minimum, a mediaType must encode the representation of the artifact (json, protobuf, encryption, compression, etc.). We should call out that this is a many to one relationship, in that you might have multiple mediaTypes representing the same content or similarly encoded content, but their handling may differ due to the mediaType. One example is the docker and oci mediatypes for indexes. They are identical formats, handling and meaning but have different mediaTypes. Another, contrived example, might be a format that uses regular OCI layers, compatible in format, but are interpreted differently by the format.

from artifacts.

mikebrow avatar mikebrow commented on June 9, 2024

just added a vote list.. to late on friday to think about it now will look at it Tuesday :-)

from artifacts.

dmcgowan avatar dmcgowan commented on June 9, 2024

This looks correct and I agree with the clarification...
but...
I still have some concerns about how CNAB is making use of the spec. I saw some work to add an optional config to OCI index to allow having that definition at the index layer as well. The current problem is that if the artifact type is in the manifest and not in the index, types which use other manifests are not well represented.

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

Thanks Derek,
I’d consider CNAB being mostly in a state of flux related to mediaTypes. I’ve been talking with @radu-matei. This is mostly due to the lack of index.config support. As a result, he’s storing the CNAB config as a manifest artifact. We need more thought on this, which is why the current artifacts prs only refer to manifests. The index work will require a rev of something, so we’ve been deferring it to a next level conversation once we get the base for Helm, Singularity, OPA and some others solid. There’s a few other registries that are waiting for this to hit a complete state for these artifacts. CNAB registry spec will continue.

from artifacts.

vsoch avatar vsoch commented on June 9, 2024

hey @SteveLasker is there a reason the second Singularity reference ("appliciation/vnd.sylabs.sif.layer.tar") points to a Helm reference?

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

To prove I’m human and demonstrate the value of PRs 🙄. I’ll fix later today.

from artifacts.

vsoch avatar vsoch commented on June 9, 2024

Ah good! I was totally convinced you were a robot 🤖 :)

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

and why you shouldn’t press button on a phone, geeze

from artifacts.

jonjohnsonjr avatar jonjohnsonjr commented on June 9, 2024

@SteveLasker can you explain the layer.config.mediaType syntax in your PR description? Layers don't have a config property in their descriptors or in the layer themselves, so where would that mediaType actually go?

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

@jonjohnsonjr - sorry, not config, just layer.mediaType: https://github.com/SteveLasker/artifacts/blob/artifact-authors-how-to/authoring-artifacts.md#defining-layer-types
Here's an example for pushing a some text files with ORAS

{
  "schemaVersion": 2,
  "config": {
    "mediaType": "application/vnd.unknown.config.v1+json",
    "digest": "sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
    "size": 2
  },
  "layers": [
    {
      "mediaType": "application/vnd.oci.image.layer.v1.txt",
      "digest": "sha256:b869b02df9f607e50536cb7fc2037e27e786d6bbc7481be25b99c4a6505768ef",
      "size": 8,
      "annotations": {
        "org.opencontainers.image.title": "layer1.txt"
      }
    },
    {
      "mediaType": "application/vnd.oci.image.layer.v1.txt",
      "digest": "sha256:35a70bc07ae77abc9970cc9234efddfc47545e85369cce75297673ba99edc32b",
      "size": 15,
      "annotations": {
        "org.opencontainers.image.title": "layer2.txt"
      }
    }
  ]
}

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

Yes, these are the details of what the values might represent. For the purpose of this clarification, we're agreeing we're using manifest.config.mediaType to define the artifact type, and layer.mediaType to define the layer type.

from artifacts.

SteveLasker avatar SteveLasker commented on June 9, 2024

Closing the issue as agreed and resolved. I'll work on updating the structure of the PRs to include a spec.md that reflects how to define and use the mediaTypes

from artifacts.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.