cluster_builder

package
v0.9.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	TemplatesRootDir = "services/terraformer/templates"
	Output           = "services/terraformer/server/clusters"
)

Variables

This section is empty.

Functions

func GroupByProvider added in v0.9.0

func GroupByProvider(nps []*spec.NodePool) iter.Seq2[ProviderTemplateGroup, []*spec.NodePool]

func GroupByTemplates added in v0.9.0

func GroupByTemplates(nps []*spec.NodePool) iter.Seq2[string, []*spec.NodePool]

Types

type ClusterBuilder

type ClusterBuilder struct {
	// DesiredClusterInfo contains the information about the
	// desired state of the cluster.
	DesiredClusterInfo *spec.ClusterInfo
	// CurrentClusterInfo contains the information about the
	// current state of the cluster.
	CurrentClusterInfo *spec.ClusterInfo
	// ProjectName is the name of the manifest.
	ProjectName string
	// ClusterType is the type of the cluster being build
	// LoadBalancer or K8s.
	ClusterType spec.ClusterType
	// K8sInfo contains additional data for when building kubernetes clusters.
	K8sInfo K8sInfo
	// LBInfo contains additional data for when building loadbalancer clusters.
	LBInfo LBInfo
	// SpawnProcessLimit represents a synchronization channel which limits the number of spawned terraform
	// processes. This values should always be non-nil and be buffered, where the capacity indicates
	// the limit.
	SpawnProcessLimit chan struct{}
}

ClusterBuilder wraps data needed for building a cluster.

func (ClusterBuilder) CreateNodepools

func (c ClusterBuilder) CreateNodepools() error

CreateNodepools creates node pools for the cluster.

func (ClusterBuilder) DestroyNodepools

func (c ClusterBuilder) DestroyNodepools() error

DestroyNodepools destroys nodepools for the cluster.

type K8sInfo added in v0.9.0

type K8sInfo struct{ LoadBalancers []*spec.LBcluster }

type LBInfo added in v0.9.0

type LBInfo struct{ Roles []*spec.Role }

type ProviderTemplateGroup added in v0.9.0

type ProviderTemplateGroup struct {
	CloudProvider string
	SpecName      string
	Creds         string
}

Jump to

Keyboard shortcuts

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