contexts

package
v0.3.4 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseContext

type BaseContext struct {
	// --registry-login + --registry-password (can be nil in this case) or --license depending on the operation requested
	RegistryAuth authn.Authenticator
	RegistryHost string // --registry (FQDN with port, if one is provided)
	RegistryPath string // --registry (path)

	DeckhouseRegistryRepo string // --source during pull, extracted from bundle data during push

	BundlePath         string // --images-bundle-path
	UnpackedImagesPath string

	Insecure            bool // --insecure
	SkipTLSVerification bool // --skip-tls-verify

	Logger Logger
}

BaseContext hold data related to pending registry mirroring operation.

type Logger

type Logger interface {
	DebugF(format string, a ...interface{})
	DebugLn(a ...interface{})

	InfoF(format string, a ...interface{})
	InfoLn(a ...interface{})

	WarnF(format string, a ...interface{})
	WarnLn(a ...interface{})

	Process(topic string, run func() error) error
}

type PullContext

type PullContext struct {
	BaseContext

	DoGOSTDigests   bool  // --gost-digest
	SkipModulesPull bool  // --no-modules
	BundleChunkSize int64 // Plain bytes

	// Only one of those 2 is filled at a single time or none at all.
	MinVersion      *semver.Version // --min-version
	SpecificVersion *semver.Version // --release
}

PullContext holds data related to pending mirroring-from-registry operation.

type PushContext

type PushContext struct {
	BaseContext
}

PushContext holds data related to pending mirroring-to-registry operation.

Jump to

Keyboard shortcuts

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