How opencontainers/image-spec works
This repository defines the OCI image format rather than implementing an image-building or distribution service. Its primary workflow is for an image implementation to produce a layout containing an index that references manifests and their configuration and layer content; validators can check format documents. The graph includes documented runtime and distribution handoffs, plus Go types and identity helpers. The tree and README support these capabilities, but the sampled code does not show an end-to-end image producer or consumer, so those implementation links are omitted.
Main entry points: manifest.go Image manifest · index.go Image index · image-layout.md Image layout · spec.md Format specification
Components 16
Image format
- Format specification
spec.md - Image layout
image-layout.md - Image layers
layer.md
Go types
- Image index
specs-go/v1/index.go - Image manifest
specs-go/v1/manifest.go - Image config
specs-go/v1/config.go - Content descriptor
specs-go/v1/descriptor.go - Media types
specs-go/v1/mediatype.go - Annotations
specs-go/v1/annotations.go - Schema version
specs-go/versioned.go
Validation
- Schema validator
schema/validator.go - JSON schemas
schema
Identity helpers
- Layer ChainID
identity/chainid.go
Other components
- Image implementation
- OCI runtime
- OCI distribution
Connections 15
- Image implementation → Format specification: follows
- Format specification → Image layout: defines
- Image layout → Image index: contains
- Image index → Image manifest: references
- Image manifest → Image config: references
- Image manifest → Image layers: references
- Image index → Content descriptor: uses
- Image manifest → Content descriptor: uses
- Image implementation → Schema validator: validates documents
- Schema validator → JSON schemas: validates against
- Image manifest → Schema version: embeds
- Image index → Schema version: embeds
- Image implementation → Layer ChainID: calculates layer identity
- Image layout → OCI runtime: unpacks for
- Image implementation → OCI distribution: pushes or pulls via