Documentation ¶
Index ¶
- Constants
- func ApplyK8sSystemJob(jobYaml, kubeConfigPath string, k8sWrapTransport WrapTransport) error
- func CordonUncordon(k8sClient *kubernetes.Clientset, nodeName string, cordoned bool) error
- func DeleteNode(k8sClient *kubernetes.Clientset, nodeName string) error
- func GetConfigMap(k8sClient *kubernetes.Clientset, configMapName string) (*v1.ConfigMap, error)
- func GetNode(k8sClient *kubernetes.Clientset, nodeName string) (*v1.Node, error)
- func GetNodeList(k8sClient *kubernetes.Clientset) (*v1.NodeList, error)
- func GetSecret(k8sClient *kubernetes.Clientset, secretName string) (*v1.Secret, error)
- func IsNodeReady(node v1.Node) bool
- func NewClient(kubeConfigPath string, k8sWrapTransport WrapTransport) (*kubernetes.Clientset, error)
- func RemoveTaintFromNodeByKey(k8sClient *kubernetes.Clientset, nodeName, taintKey string) error
- func SyncLabels(k8sClient *kubernetes.Clientset, nodeName string, ...) error
- func SyncTaints(k8sClient *kubernetes.Clientset, nodeName string, ...) error
- func UpdateClusterRoleBindingFromYaml(k8sClient *kubernetes.Clientset, clusterRoleBindingYaml string) error
- func UpdateClusterRoleFromYaml(k8sClient *kubernetes.Clientset, clusterRoleYaml string) error
- func UpdateConfigMap(k8sClient *kubernetes.Clientset, configYaml []byte, configMapName string) error
- func UpdatePodSecurityPolicyFromYaml(k8sClient *kubernetes.Clientset, pspYaml string) error
- func UpdateRoleBindingFromYaml(k8sClient *kubernetes.Clientset, roleBindingYaml string) error
- func UpdateRoleFromYaml(k8sClient *kubernetes.Clientset, roleYaml string) error
- func UpdateSecret(k8sClient *kubernetes.Clientset, secretDataMap map[string][]byte, ...) error
- func UpdateServiceAccountFromYaml(k8sClient *kubernetes.Clientset, serviceAccountYaml string) error
- type WrapTransport
Constants ¶
View Source
const ( DefaultRetries = 5 DefaultSleepSeconds = 5 )
View Source
const (
HostnameLabel = "kubernetes.io/hostname"
)
Variables ¶
This section is empty.
Functions ¶
func ApplyK8sSystemJob ¶
func ApplyK8sSystemJob(jobYaml, kubeConfigPath string, k8sWrapTransport WrapTransport) error
func CordonUncordon ¶
func CordonUncordon(k8sClient *kubernetes.Clientset, nodeName string, cordoned bool) error
func DeleteNode ¶
func DeleteNode(k8sClient *kubernetes.Clientset, nodeName string) error
func GetConfigMap ¶
func GetNodeList ¶
func GetNodeList(k8sClient *kubernetes.Clientset) (*v1.NodeList, error)
func IsNodeReady ¶
func NewClient ¶
func NewClient(kubeConfigPath string, k8sWrapTransport WrapTransport) (*kubernetes.Clientset, error)
func RemoveTaintFromNodeByKey ¶
func RemoveTaintFromNodeByKey(k8sClient *kubernetes.Clientset, nodeName, taintKey string) error
func SyncLabels ¶ added in v0.1.1
func SyncTaints ¶ added in v0.1.1
func SyncTaints(k8sClient *kubernetes.Clientset, nodeName string, toAddTaints, toDelTaints []string) error
func UpdateClusterRoleBindingFromYaml ¶
func UpdateClusterRoleBindingFromYaml(k8sClient *kubernetes.Clientset, clusterRoleBindingYaml string) error
func UpdateClusterRoleFromYaml ¶
func UpdateClusterRoleFromYaml(k8sClient *kubernetes.Clientset, clusterRoleYaml string) error
func UpdateConfigMap ¶
func UpdateConfigMap(k8sClient *kubernetes.Clientset, configYaml []byte, configMapName string) error
func UpdatePodSecurityPolicyFromYaml ¶
func UpdatePodSecurityPolicyFromYaml(k8sClient *kubernetes.Clientset, pspYaml string) error
func UpdateRoleBindingFromYaml ¶
func UpdateRoleBindingFromYaml(k8sClient *kubernetes.Clientset, roleBindingYaml string) error
func UpdateRoleFromYaml ¶
func UpdateRoleFromYaml(k8sClient *kubernetes.Clientset, roleYaml string) error
func UpdateSecret ¶
func UpdateServiceAccountFromYaml ¶
func UpdateServiceAccountFromYaml(k8sClient *kubernetes.Clientset, serviceAccountYaml string) error
Types ¶
type WrapTransport ¶ added in v0.1.2
type WrapTransport func(rt http.RoundTripper) http.RoundTripper
Click to show internal directories.
Click to hide internal directories.