node

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2025 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoCloudProvider     = errors.New("no cloud provider provided")
	ErrNilKubernetesClient = errors.New("kubernetes client is nil")
)
View Source
var ErrInstancesNotSupported = errors.New("cloud provider does not support instances")

Functions

func CleanUpVolumeAttachmentsForNode

func CleanUpVolumeAttachmentsForNode(ctx context.Context, kubeClient clientset.Interface, nodeName string) error

func StartCloudNodeLifecycleControllerWrapper

func StartCloudNodeLifecycleControllerWrapper(initContext app.ControllerInitContext,
	completedConfig *config.CompletedConfig,
	cloud cloudprovider.Interface,
) app.InitFunc

StartCloudNodeLifecycleControllerWrapper is used to take cloud config as input and start cloud node lifecycle controller.

Types

type CloudNodeLifecycleController

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

CloudNodeLifecycleController is responsible for deleting/updating kubernetes nodes that have been deleted/shutdown on the cloud provider.

func NewCloudNodeLifecycleController

func NewCloudNodeLifecycleController(
	nodeInformer coreinformers.NodeInformer,
	kubeClient clientset.Interface,
	cloud cloudprovider.Interface,
	nodeMonitorPeriod time.Duration,
) (*CloudNodeLifecycleController, error)

func (*CloudNodeLifecycleController) MonitorNodes

func (c *CloudNodeLifecycleController) MonitorNodes(ctx context.Context)

MonitorNodes checks to see if nodes in the cluster have been deleted or shutdown. If deleted, it deletes the node resource. If shutdown it applies a shutdown taint to the node.

func (*CloudNodeLifecycleController) Run

Run starts the main loop for this controller. Run is blocking so should be called via a goroutine.

Jump to

Keyboard shortcuts

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