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 ¶
CleanupInProgressLayers removes incomplete layers from the cache.
func CommonOpts ¶
CommonOpts returns a set of common options for crane under Zarf.
func SaveConcurrent ¶
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 ¶
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 ¶
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 ¶
WithBasicAuth returns an option for crane that sets basic auth.
func WithGlobalInsecureFlag ¶
WithGlobalInsecureFlag returns an option for crane that configures insecure based upon Zarf's global --insecure-skip-tls-verify (and --insecure) flags.
func WithPullAuth ¶
func WithPullAuth(ri types.RegistryInfo) crane.Option
WithPullAuth returns an option for crane that sets pull auth from a given registry info.
func WithPushAuth ¶
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 ¶
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 ¶
type PushConfig struct { SourceDirectory string ImageList []transform.Image RegInfo types.RegistryInfo NoChecksum bool Arch string Retries int }
PushConfig is the configuration for pushing images.