kubernetes

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2022 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() resource.Resource

New returns a new configured resource

Types

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"`
	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"`
}

Cluster is the schema model

func (*Cluster) Transform

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

Transform transforms clusters.Cluster structure to Cluster

type Extensions

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

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 added in v1.0.0

Configure the resource client

func (Resource) Create

Create - lifecycle function

func (Resource) Delete

Delete - lifecycle function

func (*Resource) GetSchema

func (r *Resource) GetSchema(_ context.Context) (tfsdk.Schema, diag.Diagnostics)

GetSchema returns the terraform schema structure

func (*Resource) ImportState

ImportState handles terraform import

func (*Resource) Metadata

Metadata returns data resource metadata

func (Resource) Read

Read - lifecycle function

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