kind: sigs.k8s.io/kind/pkg/cluster/nodeutils Index | Files

package nodeutils

import "sigs.k8s.io/kind/pkg/cluster/nodeutils"

Package nodeutils contains functionality for Kubernetes-in-Docker nodes It mostly exists to break up functionality from sigs.k8s.io/kind/pkg/cluster

Index

Package Files

doc.go roles.go util.go

func APIServerEndpointNode Uses

func APIServerEndpointNode(allNodes []nodes.Node) (nodes.Node, error)

APIServerEndpointNode selects the node from allNodes which hosts the API Server endpoint This should be the control plane node if there is one control plane node, or a LoadBalancer otherwise. It returns an error if the node list is invalid (E.G. two control planes and no load balancer)

func BootstrapControlPlaneNode Uses

func BootstrapControlPlaneNode(allNodes []nodes.Node) (nodes.Node, error)

BootstrapControlPlaneNode returns a handle to the bootstrap control plane node TODO(bentheelder): remove this. This node shouldn't be special (fix that first)

func ControlPlaneNodes Uses

func ControlPlaneNodes(allNodes []nodes.Node) ([]nodes.Node, error)

ControlPlaneNodes returns all control plane nodes such that the first entry is the bootstrap control plane node

func CopyNodeToNode Uses

func CopyNodeToNode(a, b nodes.Node, file string) error

CopyNodeToNode copies file from a to b

func ExternalLoadBalancerNode Uses

func ExternalLoadBalancerNode(allNodes []nodes.Node) (nodes.Node, error)

ExternalLoadBalancerNode returns a node handle for the external control plane loadbalancer node or nil if there isn't one

func GetControlPlaneEndpoint Uses

func GetControlPlaneEndpoint(allNodes []nodes.Node) (string, string, error)

GetControlPlaneEndpoint returns the control plane endpoints for IPv4 and IPv6 in case the cluster has an external load balancer in front of the control-plane nodes, otherwise return the bootstrap node IPs

func ImageID Uses

func ImageID(n nodes.Node, image string) (string, error)

ImageID returns ID of image on the node with the given image name if present

func KubeVersion Uses

func KubeVersion(n nodes.Node) (version string, err error)

KubeVersion returns the Kubernetes version installed on the node

func LoadImageArchive Uses

func LoadImageArchive(n nodes.Node, image io.Reader) error

LoadImageArchive loads image onto the node, where image is a Reader over an image archive

func SecondaryControlPlaneNodes Uses

func SecondaryControlPlaneNodes(allNodes []nodes.Node) ([]nodes.Node, error)

SecondaryControlPlaneNodes returns handles to the secondary control plane nodes and NOT the bootstrap control plane node

func SelectNodesByRole Uses

func SelectNodesByRole(allNodes []nodes.Node, role string) ([]nodes.Node, error)

SelectNodesByRole returns a list of nodes with the matching role TODO(bentheelder): remove this in favor of specific role select methods and avoid the unnecessary error handling

func WriteFile Uses

func WriteFile(n nodes.Node, dest, content string) error

WriteFile writes content to dest on the node

Package nodeutils imports 12 packages (graph) and is imported by 9 packages. Updated 2019-11-11. Refresh now. Tools for package owners.