cmd

package
v1.1.0-rc3 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2020 License: Apache-2.0 Imports: 18 Imported by: 3

Documentation

Index

Constants

View Source
const (
	// the port where prometheus metrics are exposed
	DefaultMetricsAddress = ":8085"

	// server's client default qps and burst
	DefaultClientQPS   float32 = 20.0
	DefaultClientBurst int     = 30

	DefaultProfilerAddress         = "localhost:6060"
	DefaultInsecureFlag       bool = true
	DefaultVCConfigFromSecret bool = true

	DefaultBackupWorkers      = 1
	DefaultRetryIntervalStart = time.Second
	DefaultRetryIntervalMax   = 5 * time.Minute
)

Variables

This section is empty.

Functions

func BuildConfig added in v1.1.0

func BuildConfig(master, kubeConfig string, f client.Factory) (*rest.Config, error)

func CheckCSIInstalled added in v1.1.0

func CheckCSIInstalled(kubeClient kubernetes.Interface) (bool, bool, error)

func CheckCSIVersion added in v1.1.0

func CheckCSIVersion(containers []v1.Container) (bool, bool, error)

func CheckError

func CheckError(err error)

CheckError prints err to stderr and exits with code 1 if err is not nil. Otherwise, it is a no-op.

func CheckPluginImageRepo added in v1.1.0

func CheckPluginImageRepo(kubeClient kubernetes.Interface, ns string, defaultImage string, serverType string) (string, error)

func CheckVSphereCSIDriverVersion added in v1.1.0

func CheckVSphereCSIDriverVersion(kubeClient kubernetes.Interface) error

func CheckVeleroVersion added in v1.1.0

func CheckVeleroVersion(kubeClient kubernetes.Interface, ns string) error

func CompareVersion added in v1.1.0

func CompareVersion(currentVersion string, minVersion string) int

If currentVersion < minVersion, return -1 If currentVersion == minVersion, return 0 If currentVersion > minVersion, return 1 Assume input versions are both valid

func CreateFeatureStateConfigMap added in v1.1.0

func CreateFeatureStateConfigMap(kubeClient kubernetes.Interface, features []string, veleroNs string) error

func Exit

func Exit(msg string, args ...interface{})

Exit prints msg (with optional args), plus a newline, to stderr and exits with code 1.

func GetCompatibleRepoAndTagFromPluginImage added in v1.1.0

func GetCompatibleRepoAndTagFromPluginImage(kubeClient kubernetes.Interface, namespace string, targetContainer string) (string, error)

func GetFeatureFlagsFromImage added in v1.1.0

func GetFeatureFlagsFromImage(containers []v1.Container, containerName string) ([]string, error)

func GetVeleroFeatureFlags added in v1.1.0

func GetVeleroFeatureFlags(kubeClient kubernetes.Interface, ns string) ([]string, error)

func GetVeleroVersion added in v1.1.0

func GetVeleroVersion(kubeClient kubernetes.Interface, ns string) (string, error)

func GetVersionFromImage added in v1.1.0

func GetVersionFromImage(containers []v1.Container, imageName string) string

Return version in the format: vX.Y.Z

func GetVersionFromImageByContainerName added in v1.1.0

func GetVersionFromImageByContainerName(containers []v1.Container, containerName string) string

Return version in the format: vX.Y.Z

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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