stack

package
v0.19.6 Latest Latest
Warning

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

Go to latest
Published: May 21, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Docker

type Docker interface {
	CheckContainerExistence(ctx context.Context, name string) (bool, error)
	ForceRemove(ctx context.Context, name string) error
	Run(ctx context.Context, image string, name string, cmd []string, flags ...string) error
}

type Helm

type Helm interface {
	RegistryLogin(ctx context.Context, endpoint, username, password string) error
	InstallChartWithValuesFile(ctx context.Context, chart, ociURI, version, kubeconfigFilePath, valuesFilePath string) error
	UpgradeChartWithValuesFile(ctx context.Context, chart, ociURI, version, kubeconfigFilePath, valuesFilePath string, opts ...helm.Opt) error
}

type InstallOption

type InstallOption func(s *Installer)

func WithBootsOnDocker

func WithBootsOnDocker() InstallOption

WithBootsOnDocker is an InstallOption to run Boots as a Docker container.

func WithBootsOnKubernetes

func WithBootsOnKubernetes() InstallOption

WithBootsOnKubernetes is an InstallOption to run Boots as a Kubernetes deployment.

func WithEnvoyEnabled added in v0.12.0

func WithEnvoyEnabled(enabled bool) InstallOption

func WithHostPortEnabled

func WithHostPortEnabled(enabled bool) InstallOption

WithHostPortEnabled is an InstallOption that allows you to enable/disable host port for Tinkerbell deployments.

func WithLoadBalancerEnabled added in v0.12.0

func WithLoadBalancerEnabled(enabled bool) InstallOption

WithLoadBalancer is an InstallOption that allows you to setup a LoadBalancer to expose hegel and tink-server.

func WithNamespaceCreate

func WithNamespaceCreate(create bool) InstallOption

WithNamespaceCreate is an InstallOption is lets you specify whether to create the namespace needed for Tinkerbell stack.

type Installer

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

func (*Installer) AddNoProxyIP added in v0.16.0

func (s *Installer) AddNoProxyIP(IP string)

AddNoProxyIP is for workload cluster upgrade, we have to pass controlPlaneEndpoint IP of managemement cluster if proxy is configured.

func (*Installer) CleanupLocalBoots

func (s *Installer) CleanupLocalBoots(ctx context.Context, remove bool) error

CleanupLocalBoots determines whether Boots is already running locally and either cleans it up or errors out depending on the `remove` flag.

func (*Installer) GetNamespace added in v0.15.0

func (s *Installer) GetNamespace() string

GetNamespace retrieves the namespace the installer is using for stack deployment.

func (*Installer) Install

func (s *Installer) Install(ctx context.Context, bundle releasev1alpha1.TinkerbellBundle, tinkerbellIP, kubeconfig, hookOverride string, opts ...InstallOption) error

Install installs the Tinkerbell stack on a target cluster using a helm chart and providing the necessary values overrides.

func (*Installer) UninstallLocal

func (s *Installer) UninstallLocal(ctx context.Context) error

UninstallLocal currently removes local docker container running Boots.

func (*Installer) Upgrade added in v0.15.0

func (s *Installer) Upgrade(ctx context.Context, bundle releasev1alpha1.TinkerbellBundle, tinkerbellIP, kubeconfig string, hookOverride string, opts ...InstallOption) error

Upgrade the Tinkerbell stack using images specified in bundle.

type StackInstaller

type StackInstaller interface {
	CleanupLocalBoots(ctx context.Context, forceCleanup bool) error
	Install(ctx context.Context, bundle releasev1alpha1.TinkerbellBundle, tinkerbellIP, kubeconfig, hookOverride string, opts ...InstallOption) error
	UninstallLocal(ctx context.Context) error
	Upgrade(_ context.Context, _ releasev1alpha1.TinkerbellBundle, tinkerbellIP, kubeconfig, hookOverride string, opts ...InstallOption) error
	AddNoProxyIP(IP string)
	GetNamespace() string
}

StackInstaller deploys a Tinkerbell stack.

func NewInstaller

func NewInstaller(docker Docker, filewriter filewriter.FileWriter, helm Helm, namespace string, podCidrRange string, registryMirror *registrymirror.RegistryMirror, proxyConfig *v1alpha1.ProxyConfiguration) StackInstaller

NewInstaller returns a Tinkerbell StackInstaller which can be used to install or uninstall the Tinkerbell stack.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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