aws

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIProvider

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

APIProvider handles AWS specific logic

func NewAPIProvider

func NewAPIProvider(pollPeriod time.Duration, filters map[string]string, nameTag string) (*APIProvider, error)

NewAPIProvider creates an AWS api instance

func (*APIProvider) DesiredGroupSize

func (d *APIProvider) DesiredGroupSize(groupName string) (int, error)

DesiredGroupSize returns the size that the instanceGroup (ASG in AWS) should be. The deletion controller shouldn't delete a node whose instanceGroup is already depleted

func (*APIProvider) DetachNode

func (d *APIProvider) DetachNode(opts *config.Ops, node *core_v1.Node) error

func (*APIProvider) OutdatedLaunchConfig

func (d *APIProvider) OutdatedLaunchConfig(opts *config.Ops, node *core_v1.Node) (bool, error)

OutdatedLaunchConfig checks if a node has become outdated compared to the ASG configuration

func (*APIProvider) PreDrain

func (d *APIProvider) PreDrain(opts *config.Ops, node *core_v1.Node) error

PreDrain removes the node from its ASG and sets the delete behavior to terminate, instead of stop

func (*APIProvider) Run

func (d *APIProvider) Run(stopCh <-chan struct{})

Run starts the polling loop that pulls information about the AWS ASGs

Jump to

Keyboard shortcuts

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