cloudprovider

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FakeCloudProviderName = "fake"
	GCPCloudProviderName  = "gcp"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudProvider

type CloudProvider interface {
	// IsSpotInstance determines whether the underlying instance of the Node is a spot instance
	IsSpotInstance(ctx context.Context, node *corev1.Node) (bool, error)
	// DeleteInstance should drain connections from external load balancers to the Node and then
	// delete the underlying instance. Implementations can assume that before this function is
	// called Pods have already been drained from the Node and it has been tainted with
	// ToBeDeletedByClusterAutoscaler to fail kube-proxy health checks as described in KEP-3836:
	// https://github.com/kubernetes/enhancements/tree/27ef0d9a740ae5058472aac4763483f0e7218c0e/keps/sig-network/3836-kube-proxy-improved-ingress-connectivity-reliability
	DeleteInstance(ctx context.Context, node *corev1.Node) error
}

CloudProvider contains the functions for interacting with a cloud provider

func NewCloudProvider

func NewCloudProvider(ctx context.Context, cloudProviderName string) (CloudProvider, error)

NewCloudProvider returns a new CloudProvider instance

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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