Documentation ¶
Index ¶
- Constants
- func MatchPlatformsForAppend(config schema.ContainConfig) (match.Matcher, error)
- type EachAppend
- type IndexManifests
- func (m *IndexManifests) BaseRef() name.Digest
- func (m *IndexManifests) GetPrototypeBase() (name.Digest, error)
- func (m *IndexManifests) PushIndex(tag name.Reference, result appender.AppendResult, ...) (v1.Hash, error)
- func (m *IndexManifests) PushWithAppend(append EachAppend, tagRef name.Reference, tagRegistry *registry.RegistryConfig) (v1.Hash, error)
- func (m *IndexManifests) SizeAppend() int
- type TaggableChild
- type TaggableIndex
- type ToAppend
Constants ¶
const ( ReferenceTypeAnnotation = "vnd.docker.reference.type" ReferenceTypeAttestation = "attestation-manifest" AttestationPlatform = "unknown/unknown" ReferenceDigestAnnotation = "vnd.docker.reference.digest" )
Variables ¶
This section is empty.
Functions ¶
func MatchPlatformsForAppend ¶ added in v0.4.2
func MatchPlatformsForAppend(config schema.ContainConfig) (match.Matcher, error)
MatchPlatformsForAppend matches only on platform equality which is stricter than platform at runtime image pull because we don't want to widen the scope of a base image (config could allow different matching as opt-in, maybe with v1.Platform.Satisfies)
Types ¶
type EachAppend ¶
type EachAppend func(baseRef name.Digest, tagRef name.Reference, tagRegistry *registry.RegistryConfig) (mutate.IndexAddendum, error)
type IndexManifests ¶
type IndexManifests struct {
// contains filtered or unexported fields
}
func NewFromMultiArchBase ¶
func NewFromMultiArchBase(config schema.ContainConfig, baseRegistry *registry.RegistryConfig) (*IndexManifests, error)
func (*IndexManifests) BaseRef ¶ added in v0.4.4
func (m *IndexManifests) BaseRef() name.Digest
func (*IndexManifests) GetPrototypeBase ¶
func (m *IndexManifests) GetPrototypeBase() (name.Digest, error)
GetPrototypeBase gets a single base to operate on as a prototype of how all archs/manifests should be mutated Deprecated: see EachAppend
func (*IndexManifests) PushIndex ¶
func (m *IndexManifests) PushIndex(tag name.Reference, result appender.AppendResult, config *registry.RegistryConfig) (v1.Hash, error)
PushIndex takes the AppendResult of the prototype contain and the original index to push a new multi-arch (i.e. multi-manifest) image Deprecated: hard to use because config can't be updated and referential consistency at push is non-trivial
func (*IndexManifests) PushWithAppend ¶
func (m *IndexManifests) PushWithAppend(append EachAppend, tagRef name.Reference, tagRegistry *registry.RegistryConfig) (v1.Hash, error)
func (*IndexManifests) SizeAppend ¶ added in v0.4.4
func (m *IndexManifests) SizeAppend() int
SizeAppend is the number of manifests we'd append to in constrast to for example SizeBase = original size, SizeResult = in the index that will be pushed
type TaggableChild ¶
type TaggableChild struct {
// contains filtered or unexported fields
}
TaggableChild allows remote.Put of an index's child manifest and holds enough metadata for the index to reference it
func NewTaggableChild ¶
func NewTaggableChild(manifest v1.Manifest) (TaggableChild, error)
func (TaggableChild) RawManifest ¶
func (t TaggableChild) RawManifest() ([]byte, error)
func (TaggableChild) Size ¶
func (t TaggableChild) Size() (int64, error)
type TaggableIndex ¶
type TaggableIndex struct {
// contains filtered or unexported fields
}
TaggableIndex wraps v1.ImageIndex so that go-containerregistry remote.Put doesn't treat it as an image
func NewTaggableIndex ¶
func NewTaggableIndex(index v1.ImageIndex) (TaggableIndex, error)
NewTaggableIndex extracts the necessary data immediately so later mutations won't affect the manifest and calls to interface methods won't err
func (TaggableIndex) RawManifest ¶
func (t TaggableIndex) RawManifest() ([]byte, error)
func (TaggableIndex) Size ¶
func (t TaggableIndex) Size() (int64, error)