registry

package
v0.0.0-...-035f276 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2022 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Digest

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

Digest represents a digest based image reference implements IImageReference interface

func NewDigest

func NewDigest(original string, registry string, repository string, digest string) *Digest

NewDigest Digest ctor

func (*Digest) Digest

func (d *Digest) Digest() string

Digest return the digest part of the reference

func (*Digest) Original

func (ref *Digest) Original() string

Original fully qualified reference

func (*Digest) Registry

func (ref *Digest) Registry() string

Registry image ref registry (e.g. "tomer.azurecr.io")

func (*Digest) Repository

func (ref *Digest) Repository() string

Repository image ref repository (e.g. "app/redis")

type IImageReference

type IImageReference interface {
	// Registry image ref registry (e.g. "tomer.azurecr.io")
	Registry() string
	// Repository image ref repository (e.g. "app/redis")
	Repository() string
	// Original fully qualified reference
	Original() string
}

IImageReference represents container image processed context and original identifier

type IRegistryClient

type IRegistryClient interface {
	// GetDigestUsingACRAttachAuth receives image reference and get it's digest using ACR attach authntication
	// ACR attach auth is based MSI token used to access the registry
	GetDigestUsingACRAttachAuth(imageReference IImageReference) (string, error)

	// GetDigestUsingK8SAuth receives image reference and get it's digest using K8S secerts and auth
	// K8S auth is based image pull secrets used in deployment or attached to service account to pull the image
	GetDigestUsingK8SAuth(imageReference IImageReference, namespace string, imagePullSecrets []string, serviceAccountName string) (string, error)

	// GetDigestUsingDefaultAuth receives image reference and get it's digest using the default docker config auth
	GetDigestUsingDefaultAuth(imageReference IImageReference) (string, error)
}

IRegistryClient container registry based client

type Tag

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

Tag represents a tag based image reference implements IImageReference interface

func NewTag

func NewTag(original string, registry string, repository string, tag string) *Tag

NewTag Tag ctor

func (*Tag) Original

func (ref *Tag) Original() string

Original fully qualified reference

func (*Tag) Registry

func (ref *Tag) Registry() string

Registry image ref registry (e.g. "tomer.azurecr.io")

func (*Tag) Repository

func (ref *Tag) Repository() string

Repository image ref repository (e.g. "app/redis")

func (*Tag) Tag

func (t *Tag) Tag() string

Tag return the tag part of the reference

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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