cluster

package
v1.30.27 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2024 License: Apache-2.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultAllowPrivileged              = true
	DefaultOSName                       = "flatcar"
	DefaultNodepoolMin            int64 = 1
	DefaultNodepoolMax            int64 = 2
	DefaultNodepoolMaxSurge       int64 = 1
	DefaultNodepoolMaxUnavailable int64 = 0
	DefaultVolumeType                   = "storage_premium_perf1"
	DefaultVolumeSizeGB           int64 = 20
	DefaultCRI                          = "containerd"
	DefaultZone                         = "eu01-m"
	DefaultVersion                      = "1.26"
)

Variables

This section is empty.

Functions

func New

func New() resource.Resource

New returns a new configured resource

Types

type ACL added in v1.10.7

type ACL struct {
	Enabled      types.Bool `tfsdk:"enabled"`
	AllowedCIDRs types.List `tfsdk:"allowed_cidrs"`
}

type ArgusExtension

type ArgusExtension struct {
	Enabled         types.Bool   `tfsdk:"enabled"`
	ArgusInstanceID types.String `tfsdk:"argus_instance_id"`
}

type Cluster

type Cluster struct {
	ID                        types.String   `tfsdk:"id"`
	Name                      types.String   `tfsdk:"name"`
	KubernetesProjectID       types.String   `tfsdk:"kubernetes_project_id"`
	ProjectID                 types.String   `tfsdk:"project_id"`
	KubernetesVersion         types.String   `tfsdk:"kubernetes_version"`
	KubernetesVersionUsed     types.String   `tfsdk:"kubernetes_version_used"`
	AllowPrivilegedContainers types.Bool     `tfsdk:"allow_privileged_containers"`
	NodePools                 []NodePool     `tfsdk:"node_pools"`
	Maintenance               *Maintenance   `tfsdk:"maintenance"`
	Hibernations              []Hibernation  `tfsdk:"hibernations"`
	Extensions                *Extensions    `tfsdk:"extensions"`
	Status                    types.String   `tfsdk:"status"`
	KubeConfig                types.String   `tfsdk:"kube_config"`
	Timeouts                  timeouts.Value `tfsdk:"timeouts"`
	NetworkID                 types.String   `tfsdk:"network_id"`
}

Cluster is the schema model

func (*Cluster) Transform

func (c *Cluster) Transform(cl cluster.Cluster)

Transform transforms clusters.Cluster structure to Cluster

type Extensions

type Extensions struct {
	Argus *ArgusExtension `tfsdk:"argus"`
	ACL   *ACL            `tfsdk:"acl"`
}

type Hibernation

type Hibernation struct {
	Start    types.String `tfsdk:"start"`
	End      types.String `tfsdk:"end"`
	Timezone types.String `tfsdk:"timezone"`
}

type Maintenance

type Maintenance struct {
	EnableKubernetesVersionUpdates   types.Bool   `tfsdk:"enable_kubernetes_version_updates"`
	EnableMachineImageVersionUpdates types.Bool   `tfsdk:"enable_machine_image_version_updates"`
	Start                            types.String `tfsdk:"start"`
	End                              types.String `tfsdk:"end"`
}

type NodePool

type NodePool struct {
	Name             types.String `tfsdk:"name"`
	MachineType      types.String `tfsdk:"machine_type"`
	OSName           types.String `tfsdk:"os_name"`
	OSVersion        types.String `tfsdk:"os_version"`
	Minimum          types.Int64  `tfsdk:"minimum"`
	Maximum          types.Int64  `tfsdk:"maximum"`
	MaxSurge         types.Int64  `tfsdk:"max_surge"`
	MaxUnavailable   types.Int64  `tfsdk:"max_unavailable"`
	VolumeType       types.String `tfsdk:"volume_type"`
	VolumeSizeGB     types.Int64  `tfsdk:"volume_size_gb"`
	Labels           types.Map    `tfsdk:"labels"`
	Taints           []Taint      `tfsdk:"taints"`
	ContainerRuntime types.String `tfsdk:"container_runtime"`
	Zones            types.List   `tfsdk:"zones"`
}

type Resource

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

Resource is the exported resource

func (*Resource) Configure

Configure the resource client

func (Resource) Create

Create - lifecycle function

func (Resource) Delete

Delete - lifecycle function

func (*Resource) ImportState

ImportState handles terraform import

func (*Resource) Metadata

Metadata returns data resource metadata

func (Resource) Read

Read - lifecycle function

func (*Resource) Schema added in v1.9.0

Schema returns the terraform schema structure

func (Resource) Update

Update - lifecycle function

type Taint

type Taint struct {
	Effect types.String `tfsdk:"effect"`
	Key    types.String `tfsdk:"key"`
	Value  types.String `tfsdk:"value"`
}

Jump to

Keyboard shortcuts

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