controlplane

package
v0.10.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeployStrategy

type DeployStrategy string

DeployStrategy enumerates different ways of deploying kube-fledged control plane

const (
	//DeployUsingYaml may be used with a controlplane.HandlerConfig to install using YAML manifests
	DeployUsingYaml DeployStrategy = "yaml"
	//DeployUsingHelmChart may be used with a controlplane.HandlerConfig to install using the helm chart files
	DeployUsingHelmChart DeployStrategy = "helm-chart"
	//DeployUsingOperator may be used with a controlplane.HandlerConfig to install using the helm operator
	DeployUsingOperator DeployStrategy = "operator"
)

type Handler

type Handler struct {
	CreateFn  func(context.Context) error
	IsCreated func(context.Context) bool
	DeleteFn  func(context.Context) error
	IsDeleted func(context.Context) bool
}

Handler is an intermittent object during control plane creation/deletion. This abstracts away the installation and deletion complexities

func NewHandler

func NewHandler(t *testing.T, config HandlerConfig) *Handler

NewHandler returns a Create-able and Delete-able object

func (*Handler) Create

func (h *Handler) Create(ctx context.Context, t *testing.T) error

Create kube-fledged control plane and verify deployment

func (*Handler) Delete

func (h *Handler) Delete(ctx context.Context, t *testing.T) error

Delete kube-fledged control plane and verify deletion

type HandlerConfig

type HandlerConfig struct {
	Strategy            DeployStrategy
	YamlDir             string
	HelmChartDir        string
	OperatorDir         string
	TestEnvConfig       *envconf.Config
	Namespace           string
	OperatorNamespace   string
	EnableWebhookServer bool
	// contains filtered or unexported fields
}

HandlerConfig is a config for the kube-fledged control plane

Jump to

Keyboard shortcuts

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