Skip to content

How To Add New Capabilities to OCI * #94

@SteveLasker

Description

@SteveLasker

How To Add New Capabilities to OCI *

We have a few issues we're all wrestling with, with varied approaches and opinions on how to solve a problem. I'd suggest we each have slightly different priorities and we're focusing on the problems we either think we need or can solve. Unfortunately, we have come to a point where we have some bottlenecks in what extensibility we have.

To help frame a discussion, I'd suggest we need a framework for the discussions:

  1. Gather a list of the core issues we collectively believe are relevant.
  2. Find the things we can agree upon.
  3. Propose some solutions, which map back to the agreed upon list.
  4. Capture the pros and cons with each approach. There is no silver bullet here

Categories of changes

We have at least 2 major categories of changes:

  1. How to add new capabilities to the container image, including compression formats:
  2. How to add signatures, and other linked artifacts

Constraints

What are the constraints we're trying to adhere to:

  1. Not break existing container runtimes, including down-level clients
  2. Not break container registries

"Not break" means we can add behaviors, but do it in a deterministic way.

Elephants in the Room

To confront, head-on, some concerns we're all facing:

  1. Is the image-spec frozen?
  2. How do we unblock innovation for various projects

Is the image-spec frozen

I don't believe anyone desires the image-spec to be frozen. Rather, the question is: How do we make changes to the image-spec without breaking down-stream clients?

The varied designs around OCI Artifacts, Notary v2, cosign/sigstore, Compression Support all bump into this question, which we haven't actually clarified.

Facts:

  • The image-spec has a declared version 1.0, dating back to August 2017.
  • Registries (implementations of the distribution-spec) use the schemas within image-spec and image-index to manage content.
  • Folks are brainstorming around OCI Image v2. It's unclear how many of these can be implemented if we don't unlock extensibility.
  • Registries store more than container images. Although OCI Artifacts was able to work within the current image-spec, there were many constraints that make this awkward.
    • Config is required and used to determine the artifactType
    • At least 1 layer is required
    • Lack support for reference types (in either direction)
  • OCI Artifacts was created with the constraint that any schema change to the image-spec would require a version change to the image-spec.
  • Although the distribution-spec doesn't explicitly call out garbage collection, delete semantics are specified are defined, and some form of content management is a requirement for any production registry.
  • The image-spec and distribution-spec exist to provide consistent user expectations for images and other artifact types as they work with various cloud providers, vendor products and OSS projects that adhere to the specs.
  • Any change will take time for adoption and will require work to be useful. Where the work is required is in the details of the various proposals, based around a set of constraints.

What types of changes can be made, and how

The question could then be sub-categorized as:

  • What changes to the spec can be done within v1?
    • Annotations, as optional strings appear to meet the bar
  • What changes require a version change?

image

Things We Agree Upon

Are we in agreement to the following?

  • Linking artifacts is needed to support signatures, SBoMs and other artifact types to be addeded, without changing the digest and/or tag.
    • There's no specifics on which signature format, nor which SBoM format here. Simply an additional artifact can be added, referencing existing artifacts
  • An API for querying the references
    • Whether this is added to the distribution-spec, or an optional extension, the API is considered matched behavior to the ability to link artifacts.

Current Proposals

There are three proposals up for consideration, with pros and cons associated with each. Before we can get into the pros & cons, there's presumptions for how OCI will support extensibility.

  1. Add a new OCI artifact manifest
  2. Add new descriptor.data field and descriptor.reference field to image-spec
  3. Add new generic object manifest
  • 1 and 2 are based on whether changes to the image-spec are possible. Conceptually, either proposal can be captured in a new manifest, or merged into the image-spec, with various limitations.
  • 1 and 2 do not account for compression formats, or other OCI Image v2 points of extensibility.
  • 1 and 2 are focused on linking new types to image-manifest and image-index objects, they don't focus on changing behavior of the existing container image toolchains.
  • 3 accounts for references and may account for OCI Image v2 extensibility options.

Decision Criteria

  1. As 2 of the proposals are based on how we can make changes to the image-spec, I'd suggest we start with describing what and how we might accept changes to image-spec.
  2. Based on the outcome of image-spec changes, we can discuss the 3 options. The 3 options can be adapted to how they apply to the image-spec change process.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions