images

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: Apache-2.0 Imports: 20 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseImageList

func ParseImageList(imageListPath string) (imageList v1alpha1.ImageList, err error)

ParseImageList attempts to initialize an ImageList object from the supplied path

Types

type Extractor

type Extractor struct {
	Log logr.Logger
}

Extractor extracts the URLs of all the docker images in a directory of manifests

func (*Extractor) Extract

func (e *Extractor) Extract(sourceDir string, output io.Writer) error

Extract all the images

func (*Extractor) ExtractImages

func (e *Extractor) ExtractImages(sourceDir string) (*v1alpha1.ImageList, error)

ExtractImages returns all the images in a source directory

type ImageDownloader

type ImageDownloader struct {
	Log              logr.Logger
	ImageList        v1alpha1.ImageList
	ImageDir         string
	SkipIfFileExists bool
	DummyDownload    bool
}

ImageDownloader handles pulling images given ImageList

func (*ImageDownloader) DownloadImagesWithRetry

func (d *ImageDownloader) DownloadImagesWithRetry(retry int) error

DownloadImagesWithRetry calls DownloadImagesToDir, retrying if errors occur

type ImageUploader

type ImageUploader struct {
	Log        logr.Logger
	ImageDir   string
	TargetRepo string
	SkipUpload bool
}

ImageUploader handles upload images to target repo given image dir

func (*ImageUploader) UploadImagesWithRetry

func (u *ImageUploader) UploadImagesWithRetry(retry int) (imageMappings []images.ImageMapping, err error)

UploadImagesWithRetry calls UploadImagesFromDir, retrying if errors occur

Jump to

Keyboard shortcuts

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