nodes

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterOutByRole

func FilterOutByRole(nodes []corev1.Node, role string) []corev1.Node

FilterOutByRole returns a new slice without nodes that have given role

Types

type NodesClient

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

NodesClient contains interface for making requests to kubernetes client.

func Client

func Client(kube kubernetes.Interface, logger *zap.SugaredLogger) *NodesClient

Client creates a new nodes client

func (*NodesClient) GuessNodeExternalAddress

func (n *NodesClient) GuessNodeExternalAddress(node *corev1.Node) *corev1.NodeAddress

GuessNodeExternalAddress tries to guess external address of a node

func (*NodesClient) RandomWorkerNode

func (n *NodesClient) RandomWorkerNode() (*corev1.Node, error)

RandomWorkerNode gets a worker node randomly

Jump to

Keyboard shortcuts

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