Skip to content

Commit

Permalink
specs-go: adding mediaType to the index and manifest structures
Browse files Browse the repository at this point in the history
Signed-off-by: Vincent Batts <[email protected]>
  • Loading branch information
vbatts committed Nov 9, 2021
1 parent 5f31485 commit dcdcb7f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions specs-go/v1/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ import "github.com/opencontainers/image-spec/specs-go"
type Index struct {
specs.Versioned

// MediaType specificies the type of this document data structure e.g. `application/vnd.oci.image.index.v1+json`
MediaType string `json:"mediaType,omitempty"`

// Manifests references platform specific manifests.
Manifests []Descriptor `json:"manifests"`

Expand Down
3 changes: 3 additions & 0 deletions specs-go/v1/manifest.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ import "github.com/opencontainers/image-spec/specs-go"
type Manifest struct {
specs.Versioned

// MediaType specificies the type of this document data structure e.g. `application/vnd.oci.image.manifest.v1+json`
MediaType string `json:"mediaType,omitempty"`

// Config references a configuration object for a container, by digest.
// The referenced configuration object is a JSON blob that the runtime uses to set up the container.
Config Descriptor `json:"config"`
Expand Down

0 comments on commit dcdcb7f

Please sign in to comment.