commands

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: MIT Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDefaultCommand

func NewDefaultCommand() *cobra.Command

NewDefaultCommand creates a new default command

func WriteManifest added in v0.7.0

func WriteManifest(manifest Manifest) error

WriteManifest writes the image manifest to disk

Types

type Auth

type Auth struct {
	Username string `yaml:"username,omitempty"`
	Password string `yaml:"password,omitempty"`
}

Auth is a username and password to log into a registry

type ContainerImage

type ContainerImage struct {
	Repository     string `yaml:"repository"`
	Version        string `yaml:"version"`
	SourceRegistry string `yaml:"source,omitempty"`
	Auth           Auth   `yaml:"auth,omitempty"`
}

ContainerImage is a container image

func (ContainerImage) Source

func (c ContainerImage) Source() string

Source returns the source image

func (ContainerImage) Target

func (c ContainerImage) Target(target Target) string

Target returns the target image

type Manifest added in v0.7.0

type Manifest struct {
	Target Target           `yaml:"target"`
	Images []ContainerImage `yaml:"images,omitempty"`
}

Manifest is a collection of images to sync

func GetManifest added in v0.7.0

func GetManifest() (Manifest, error)

GetManifest returns the current manifest file in the working directory

func NewAutodetectManifest added in v0.7.0

func NewAutodetectManifest(target string, path string) (Manifest, error)

NewAutodetectManifest returns a new image manifest with images found in the repository

func NewManifest added in v0.7.0

func NewManifest(target string) Manifest

NewManifest returns a new image manifest

type Target

type Target struct {
	Registry   string `yaml:"registry"`
	Repository string `yaml:"repository,omitempty"`
}

Target is the registry and repository to sync images to

func (Target) String

func (t Target) String() string

Jump to

Keyboard shortcuts

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