install

package
v0.9.1 Latest Latest
Warning

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

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

Documentation

Overview

Package install ...

Index

Constants

View Source
const (

	// SystemNamespace is the namespace where everest is installed.
	SystemNamespace = "everest-system"
	// MonitoringNamespace is the namespace where the monitoring stack is installed.
	MonitoringNamespace = "everest-monitoring"
	// EverestMonitoringNamespaceEnvVar is the name of the environment variable that holds the monitoring namespace.
	EverestMonitoringNamespaceEnvVar = "MONITORING_NAMESPACE"
)

Variables

View Source
var (
	// ErrNSEmpty appears when the provided list of the namespaces is considered empty.
	ErrNSEmpty = errors.New("namespace list is empty. Specify at least one namespace")
	// ErrNSReserved appears when some of the provided names are forbidden to use.
	ErrNSReserved = func(ns string) error {
		return fmt.Errorf("'%s' namespace is reserved for Everest internals. Please specify another namespace", ns)
	}
	// ErrNameNotRFC1035Compatible appears when some of the provided names are not RFC1035 compatible.
	ErrNameNotRFC1035Compatible = func(fieldName string) error {
		return fmt.Errorf(`'%s' is not RFC 1035 compatible. The name should contain only lowercase alphanumeric characters or '-', start with an alphabetic character, end with an alphanumeric character`,
			fieldName,
		)
	}
)

Functions

func ValidateNamespaces

func ValidateNamespaces(str string) ([]string, error)

ValidateNamespaces validates a comma-separated namespaces string.

Types

type Config

type Config struct {
	// Namespaces is a user-defined string represents raw non-validated comma-separated list of namespaces for everest to operate in.
	Namespaces string `mapstructure:"namespaces"`
	// NamespacesList validated list of namespaces that everest can operate in.
	NamespacesList []string `mapstructure:"namespaces-map"`
	// SkipWizard skips wizard during installation.
	SkipWizard bool `mapstructure:"skip-wizard"`
	// KubeconfigPath is a path to a kubeconfig
	KubeconfigPath string `mapstructure:"kubeconfig"`

	Operator OperatorConfig
}

Config stores configuration for the operators.

type Install

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

Install implements the main logic for commands.

func NewInstall

func NewInstall(c Config, l *zap.SugaredLogger) (*Install, error)

NewInstall returns a new Install struct.

func (*Install) Run

func (o *Install) Run(ctx context.Context) error

Run runs the operators installation process.

type OperatorConfig

type OperatorConfig struct {
	// PG stores if PostgresSQL shall be installed.
	PG bool `mapstructure:"postgresql"`
	// PSMDB stores if MongoDB shall be installed.
	PSMDB bool `mapstructure:"mongodb"`
	// PXC stores if XtraDB Cluster shall be installed.
	PXC bool `mapstructure:"xtradb-cluster"`
}

OperatorConfig identifies which operators shall be installed.

Jump to

Keyboard shortcuts

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