image

package
v0.4.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const RemoteHead key = "ec.image.remoteHead"

Variables

This section is empty.

Functions

func ValidateImage

func ValidateImage(ctx context.Context, comp app.SnapshotComponent, p policy.Policy, evaluators []evaluator.Evaluator, detailed bool) (*output.Output, error)

ValidateImage executes the required method calls to evaluate a given policy against a given image url.

Types

type ImageReference

type ImageReference struct {
	Repository string
	Digest     string
	Tag        string
	// contains filtered or unexported fields
}

func NewImageReference

func NewImageReference(url string, opts ...name.Option) (*ImageReference, error)

NewImageReference returns an ImageReference instance based on the given url.

func ParseAndResolve

func ParseAndResolve(ctx context.Context, url string, opts ...name.Option) (*ImageReference, error)

ParseAndResolve parses the url into an ImageReference object. The digest is resolved if needed.

func ParseAndResolveAll

func ParseAndResolveAll(ctx context.Context, urls []string, opts ...name.Option) ([]ImageReference, error)

ParseAndResolveAll is like ParseAndResolve, but for a list of urls.

func (ImageReference) Ref

func (i ImageReference) Ref() name.Reference

func (*ImageReference) String

func (i *ImageReference) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL