registry

package
v0.0.0-...-a3a5c94 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFreeImageres

func NewFreeImageres(reg *registry.Registry) map[string]FreeImager

NewFreeImageres creates a list of new FreeImager.

Types

type Cleaner

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

Cleaner is responsible for cleaning up the free images in registry.

func NewRegistryCleaner

func NewRegistryCleaner(url, username, password string) (*Cleaner, error)

NewRegistryCleaner creates a new Cleaner.

func (*Cleaner) Cleanup

func (r *Cleaner) Cleanup()

Cleanup cleans up the free image in the registry.

func (*Cleaner) DeleteImages

func (r *Cleaner) DeleteImages(freeImages []*FreeImage) error

DeleteImages deletes images.

func (*Cleaner) ListFreeImages

func (r *Cleaner) ListFreeImages() []*FreeImage

ListFreeImages return a list of free images needed to be cleaned up.

type FreeComponent

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

FreeComponent is resposible for listing the free images belong to free components.

func NewFreeComponent

func NewFreeComponent(reg *registry.Registry) *FreeComponent

NewFreeComponent creates a new FreeComponent.

func (*FreeComponent) List

func (f *FreeComponent) List() ([]*FreeImage, error)

List return a list of free images belong to free components.

type FreeImage

type FreeImage struct {
	Repository string
	Digest     string
	Tag        string
	Type       string
}

FreeImage represents a free image.

func (*FreeImage) Key

func (f *FreeImage) Key() string

Key returns the key of the FreeImaeg.

type FreeImageType

type FreeImageType string

FreeImageType is the type of FreeImage

var (
	FreeImageTypeFreeComponent FreeImageType = "FreeComponent"
	FreeImageTypeFreeVersion   FreeImageType = "FreeVersion"
)

FreeImageType -

type FreeImager

type FreeImager interface {
	List() ([]*FreeImage, error)
}

FreeImager is resposible for listing the free images.

type FreeVersion

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

FreeVersion is resposible for listing the free images belong to free component versions.

func NewFreeVersion

func NewFreeVersion(reg *registry.Registry) *FreeVersion

NewFreeVersion creates a free version.

func (*FreeVersion) List

func (f *FreeVersion) List() ([]*FreeImage, error)

List return a list of free images belong to free component versions.

Jump to

Keyboard shortcuts

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