imageset

package
v0.36.8 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImageSet

type ImageSet struct {
	// contains filtered or unexported fields
}

func NewImageSet

func NewImageSet(concurrency int, logger Logger, tagGen util.TagGenerator) ImageSet

NewImageSet constructor for creating an ImageSet

func (ImageSet) Export

func (i ImageSet) Export(foundImages *UnprocessedImageRefs,
	imagesMetadata registry.ImagesReader) (*imagedesc.ImageRefDescriptors, error)

func (*ImageSet) Import

func (i *ImageSet) Import(imgOrIndexes []imagedesc.ImageOrIndex,
	importRepo regname.Repository, registry registry.ImagesReaderWriter) (*ProcessedImages, error)

func (ImageSet) Relocate

func (i ImageSet) Relocate(foundImages *UnprocessedImageRefs,
	importRepo regname.Repository, registry registry.ImagesReaderWriter) (*ProcessedImages, error)

type Logger

type Logger interface {
	Logf(str string, args ...interface{})
}

type ProcessedImage

type ProcessedImage struct {
	UnprocessedImageRef
	DigestRef string

	Image      regv1.Image
	ImageIndex regv1.ImageIndex
}

func (ProcessedImage) Key

func (p ProcessedImage) Key() string

func (ProcessedImage) Validate

func (p ProcessedImage) Validate()

type ProcessedImages

type ProcessedImages struct {
	// contains filtered or unexported fields
}

func NewProcessedImages

func NewProcessedImages() *ProcessedImages

func (*ProcessedImages) Add

func (i *ProcessedImages) Add(img ProcessedImage)

func (*ProcessedImages) All

func (i *ProcessedImages) All() []ProcessedImage

func (*ProcessedImages) FindByURL

func (i *ProcessedImages) FindByURL(unprocessedImageURL UnprocessedImageRef) (ProcessedImage, bool)

func (*ProcessedImages) Len

func (i *ProcessedImages) Len() int

Len returns the length of Processed Images

type TarImageSet

type TarImageSet struct {
	// contains filtered or unexported fields
}

func NewTarImageSet

func NewTarImageSet(imageSet ImageSet, concurrency int, logger Logger) TarImageSet

NewTarImageSet provides export/import operations on a tarball for a set of images

func (TarImageSet) Export

func (i TarImageSet) Export(foundImages *UnprocessedImageRefs, outputPath string, registry registry.ImagesReaderWriter, imageLayerWriterCheck imagetar.ImageLayerWriterFilter, resume bool) (d *imagedesc.ImageRefDescriptors, err error)

Export Creates a Tar with the provided Images

func (*TarImageSet) Import

func (i *TarImageSet) Import(path string, importRepo regname.Repository, registry registry.ImagesReaderWriter) (*ProcessedImages, error)

Import Copy tar with Images to the Registry

type UnprocessedImageRef

type UnprocessedImageRef struct {
	DigestRef string
	Tag       string
	Labels    map[string]string
	OrigRef   string
}

func (UnprocessedImageRef) Key

func (u UnprocessedImageRef) Key() string

func (UnprocessedImageRef) Validate

func (u UnprocessedImageRef) Validate()

type UnprocessedImageRefs

type UnprocessedImageRefs struct {
	// contains filtered or unexported fields
}

func NewUnprocessedImageRefs

func NewUnprocessedImageRefs() *UnprocessedImageRefs

func (*UnprocessedImageRefs) Add

func (*UnprocessedImageRefs) All

func (*UnprocessedImageRefs) Length

func (i *UnprocessedImageRefs) Length() int

Jump to

Keyboard shortcuts

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