nodeclaim

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2024 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KaitoNodePoolName             = "kaito"
	LabelNodePool                 = "karpenter.sh/nodepool"
	ErrorInstanceTypesUnavailable = "all requested instance types were unavailable during launch"
	NodeClassName                 = "default"
)

Variables

This section is empty.

Functions

func CheckNodeClaimStatus

func CheckNodeClaimStatus(ctx context.Context, nodeClaimObj *v1beta1.NodeClaim, kubeClient client.Client) error

CheckNodeClaimStatus checks the status of the nodeClaim. If the nodeClaim is not ready, then it will wait for the nodeClaim to be ready. If the nodeClaim is not ready after the timeout, then it will return an error. if the nodeClaim is ready, then it will return nil.

func CheckNodeClass added in v0.3.1

func CheckNodeClass(ctx context.Context, kClient client.Client) error

CheckNodeClass checks if Karpenter NodeClass is available. If not, the controller will create it automatically. This is only applicable when Karpenter feature flag is enabled.

func CreateKarpenterNodeClass added in v0.3.1

func CreateKarpenterNodeClass(ctx context.Context, kubeClient client.Client) error

CreateKarpenterNodeClass creates a nodeClass object for Karpenter.

func CreateNodeClaim

func CreateNodeClaim(ctx context.Context, nodeClaimObj *v1beta1.NodeClaim, kubeClient client.Client) error

CreateNodeClaim creates a nodeClaim object.

func GenerateAKSNodeClassManifest added in v0.3.1

func GenerateAKSNodeClassManifest(ctx context.Context) *azurev1alpha2.AKSNodeClass

func GenerateEC2NodeClassManifest added in v0.3.1

func GenerateEC2NodeClassManifest(ctx context.Context) *awsv1beta1.EC2NodeClass

func GenerateNodeClaimManifest

func GenerateNodeClaimManifest(ctx context.Context, storageRequirement string, workspaceObj *kaitov1alpha1.Workspace) *v1beta1.NodeClaim

GenerateNodeClaimManifest generates a nodeClaim object from the given workspace.

func GenerateNodeClaimName

func GenerateNodeClaimName(workspaceObj *kaitov1alpha1.Workspace) string

func IsNodeClassAvailable added in v0.3.1

func IsNodeClassAvailable(ctx context.Context, cloudName string, kubeClient client.Client) bool

func ListNodeClaimByWorkspace

func ListNodeClaimByWorkspace(ctx context.Context, workspaceObj *kaitov1alpha1.Workspace, kubeClient client.Client) (*v1beta1.NodeClaimList, error)

ListNodeClaimByWorkspace list all nodeClaim objects in the cluster that are created by the workspace identified by the label.

func WaitForPendingNodeClaims

func WaitForPendingNodeClaims(ctx context.Context, workspaceObj *kaitov1alpha1.Workspace, kubeClient client.Client) error

WaitForPendingNodeClaims checks if the there are any nodeClaims in provisioning condition. If so, wait until they are ready.

Types

This section is empty.

Jump to

Keyboard shortcuts

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