package match
import "github.com/google/go-containerregistry/pkg/v1/match"
Package match provides functionality for conveniently matching a v1.Descriptor.
Index ¶
Types ¶
type Matcher ¶
type Matcher func(desc v1.Descriptor) bool
Matcher function that is given a v1.Descriptor, and returns whether or not it matches a given rule. Can match on anything it wants in the Descriptor.
func Annotation ¶
Annotation returns a match.Matcher that matches based on the provided annotation.
func Digests ¶
Digests returns a match.Matcher that matches at least one of the provided Digests
func MediaTypes ¶
MediaTypes returns a match.Matcher that matches at least one of the provided media types.
func Name ¶
Name returns a match.Matcher that matches based on the value of the
"org.opencontainers.image.ref.name" annotation:
github.com/opencontainers/image-spec/blob/v1.0.1/annotations.md#pre-defined-annotation-keys
func Platforms ¶
Platforms returns a match.Matcher that matches on any one of the provided platforms. Ignores any descriptors that do not have a platform.
Source Files ¶
- Version
- v0.20.3 (latest)
- Published
- Jan 15, 2025
- Platform
- linux/amd64
- Imports
- 2 packages
- Last checked
- 17 hours ago –
Tools for package owners.