k8s

package
v0.0.11-alpha Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Copyright (c) Microsoft Corporation. Licensed under the MIT License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientSet

type ClientSet struct {
	kubernetes.Interface

	// InPod indicates whether the current runtime environment is a pod.
	InPod bool

	// Namespace is the namespace in which to run the leader election.
	Namespace string

	// Name is the name of this pod or node.
	Name string
}

ClientSet is an interface for k8s API server.

func NewKubernetesInterface

func NewKubernetesInterface(kubeConfigPath, name string) (*ClientSet, error)

NewKubernetesInterface creates a new interface for k8s API server. The current runtime environment is first assumed to be a pod and its identity is used to create the interface. If a pod is not detected, the given kubeConfigPath is used to create the interface.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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