images

package
v3.1.7 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2024 License: Apache-2.0 Imports: 25 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultRegistry added in v3.1.7

func DefaultRegistry() string

DefaultRegistry is used to get default registry address.

func NewManifestSpec

func NewManifestSpec(image string, entries []manifesttypes.ManifestEntry) manifesttypes.YAMLInput

func ParseArchVariant

func ParseArchVariant(platform string) (string, string)

ParseArchVariant Ex: amd64 returns amd64, "" arm/v8 returns arm, v8

func ParseImageTag

func ParseImageTag(repos string) (string, string)

ParseImageTag Get a repos name and returns the right reposName + tag The tag can be confusing because of a port in a repository name.

Ex: localhost.localdomain:5000/samalba/hipache:latest

func ParseImageWithArchTag

func ParseImageWithArchTag(ref string) (string, ocispec.Platform)

Types

type CopyImageOptions

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

func (*CopyImageOptions) Copy

func (c *CopyImageOptions) Copy() error

type CopyImagesToLocalModule

type CopyImagesToLocalModule struct {
	common.ArtifactModule
	ImageStartIndex int
	ImageTransport  string
}

func (*CopyImagesToLocalModule) Init

func (c *CopyImagesToLocalModule) Init()

type CopyImagesToRegistry

type CopyImagesToRegistry struct {
	common.KubeAction
	ImagesPath     string
	ImageTransport string
}

func (*CopyImagesToRegistry) Execute

func (c *CopyImagesToRegistry) Execute(runtime connector.Runtime) error

type CopyImagesToRegistryModule

type CopyImagesToRegistryModule struct {
	common.KubeModule
	Skip           bool
	ImagePath      string
	ImageTransport string
}

func (*CopyImagesToRegistryModule) Init

func (c *CopyImagesToRegistryModule) Init()

func (*CopyImagesToRegistryModule) IsSkip

func (c *CopyImagesToRegistryModule) IsSkip() bool

type Image

type Image struct {
	RepoAddr          string
	Namespace         string
	NamespaceOverride string
	Repo              string
	Tag               string
	Group             string
	Enable            bool
}

Image defines image's info.

func GetImage

func GetImage(runtime connector.ModuleRuntime, kubeConf *common.KubeConf, name string) Image

GetImage defines the list of all images and gets image object by name.

func (Image) ImageName

func (image Image) ImageName() string

ImageName is used to generate image's full name.

func (Image) ImageNamespace added in v3.1.0

func (image Image) ImageNamespace() string

ImageNamespace is used to get image's namespace

func (Image) ImageRegistryAddr added in v3.1.0

func (image Image) ImageRegistryAddr() string

ImageRegistryAddr is used to get image's registry address.

func (Image) ImageRepo

func (image Image) ImageRepo() string

ImageRepo is used to generate image's repo address.

type Images

type Images struct {
	Images []Image
}

Images contains a list of Image

func (*Images) PullImages

func (images *Images) PullImages(runtime connector.Runtime, kubeConf *common.KubeConf) error

PullImages is used to pull images in the list of Image.

type Index

type Index struct {
	Manifests []Manifest
}

func NewIndex

func NewIndex() *Index

type Manifest

type Manifest struct {
	Annotations annotations
}

type PullImage

type PullImage struct {
	common.KubeAction
}

func (*PullImage) Execute

func (p *PullImage) Execute(runtime connector.Runtime) error

type PullModule

type PullModule struct {
	common.KubeModule
	Skip bool
}

func (*PullModule) Init

func (p *PullModule) Init()

func (*PullModule) IsSkip

func (p *PullModule) IsSkip() bool

type PushManifest

type PushManifest struct {
	common.KubeAction
}

func (*PushManifest) Execute

func (p *PushManifest) Execute(_ connector.Runtime) error

type SaveImages

type SaveImages struct {
	common.ArtifactAction
	ImageStartIndex int
	ImageTransport  string
}

func (*SaveImages) Execute

func (s *SaveImages) Execute(runtime connector.Runtime) error

type ShouldPushManifest added in v3.1.2

type ShouldPushManifest struct {
	common.KubePrepare
	ImageTransport string
}

func (*ShouldPushManifest) PreCheck added in v3.1.2

func (m *ShouldPushManifest) PreCheck(_ connector.Runtime) (bool, error)

Jump to

Keyboard shortcuts

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