taints

package
v1.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2022 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

package taints implements utilities for working with taints

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddOrUpdateTaint

func AddOrUpdateTaint(node *v1.Node, taint *v1.Taint) (*v1.Node, bool, error)

AddOrUpdateTaint tries to add a taint to annotations list. Returns a new copy of updated Node and true if something was updated false otherwise.

func DeleteTaint

func DeleteTaint(taints []v1.Taint, taintToDelete *v1.Taint) ([]v1.Taint, bool)

DeleteTaint removes all the taints that have the same key and effect to given taintToDelete.

func RemoveTaint

func RemoveTaint(node *v1.Node, taint *v1.Taint) (*v1.Node, bool, error)

RemoveTaint tries to remove a taint from annotations list. Returns a new copy of updated Node and true if something was updated false otherwise.

func TaintExists

func TaintExists(taints []v1.Taint, taintToFind *v1.Taint) bool

TaintExists checks if the given taint exists in list of taints. Returns true if exists false otherwise.

func TaintSetDiff

func TaintSetDiff(t1, t2 []v1.Taint) (taintsToAdd []*v1.Taint, taintsToRemove []*v1.Taint)

func TaintSetFilter

func TaintSetFilter(taints []v1.Taint, fn func(*v1.Taint) bool) []v1.Taint

Types

This section is empty.

Jump to

Keyboard shortcuts

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