Documentation ¶
Overview ¶
Package images provides functions for building and pushing images.
Package images provides functions for building and pushing images.
Package images provides functions for building and pushing images.
Index ¶
- func CleanupInProgressLayers(ctx context.Context, img v1.Image) error
- func CommonOpts(arch string) []crane.Option
- func NoopOpt(*crane.Options)
- func Pull(ctx context.Context, cfg PullConfig) (map[transform.Image]v1.Image, error)
- func Push(ctx context.Context, cfg PushConfig) error
- func SaveConcurrent(ctx context.Context, cl clayout.Path, m map[transform.Image]v1.Image) (map[transform.Image]v1.Image, error)
- func SaveSequential(ctx context.Context, cl clayout.Path, m map[transform.Image]v1.Image) (map[transform.Image]v1.Image, error)
- func WithArchitecture(arch string) crane.Option
- func WithBasicAuth(username, password string) crane.Option
- func WithGlobalInsecureFlag() []crane.Option
- func WithPullAuth(ri types.RegistryInfo) crane.Option
- func WithPushAuth(ri types.RegistryInfo) crane.Option
- type PullConfig
- type PushConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanupInProgressLayers ¶ added in v0.34.0
CleanupInProgressLayers removes incomplete layers from the cache.
func CommonOpts ¶ added in v0.34.0
CommonOpts returns a set of common options for crane under Zarf.
func Push ¶ added in v0.34.0
func Push(ctx context.Context, cfg PushConfig) error
Push pushes images to a registry.
func SaveConcurrent ¶ added in v0.34.0
func SaveConcurrent(ctx context.Context, cl clayout.Path, m map[transform.Image]v1.Image) (map[transform.Image]v1.Image, error)
SaveConcurrent saves images in a concurrent, bounded manner.
func SaveSequential ¶ added in v0.34.0
func SaveSequential(ctx context.Context, cl clayout.Path, m map[transform.Image]v1.Image) (map[transform.Image]v1.Image, error)
SaveSequential saves images sequentially.
func WithArchitecture ¶ added in v0.34.0
WithArchitecture sets the platform option for crane.
This option is actually a slight mis-use of the platform option, as it is setting the architecture only and hard coding the OS to linux.
func WithBasicAuth ¶ added in v0.34.0
WithBasicAuth returns an option for crane that sets basic auth.
func WithGlobalInsecureFlag ¶ added in v0.34.0
WithGlobalInsecureFlag returns an option for crane that configures insecure based upon Zarf's global --insecure flag.
func WithPullAuth ¶ added in v0.34.0
func WithPullAuth(ri types.RegistryInfo) crane.Option
WithPullAuth returns an option for crane that sets pull auth from a given registry info.
func WithPushAuth ¶ added in v0.34.0
func WithPushAuth(ri types.RegistryInfo) crane.Option
WithPushAuth returns an option for crane that sets push auth from a given registry info.
Types ¶
type PullConfig ¶ added in v0.34.0
type PullConfig struct { DestinationDirectory string ImageList []transform.Image Arch string RegistryOverrides map[string]string CacheDirectory string }
PullConfig is the configuration for pulling images.
type PushConfig ¶ added in v0.34.0
type PushConfig struct { SourceDirectory string ImageList []transform.Image RegInfo types.RegistryInfo NoChecksum bool Arch string Retries int }
PushConfig is the configuration for pushing images.