client

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2025 License: Apache-2.0 Imports: 44 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ManagedByLabel = "app.kubernetes.io/managed-by"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterInfo

type ClusterInfo struct {
	Version      string
	Distribution core.KubernetesDistribution
}

type Diff

type Diff struct {
	Resource  string
	Namespace string
	DiffText  string
	DiffType  DiffType
}

type DiffType

type DiffType string
var (
	DiffTypeAdded    DiffType = "A"
	DiffTypeDeleted  DiffType = "D"
	DiffTypeModified DiffType = "M"
)

type KubernetesClient

type KubernetesClient struct {
	Factory       cmdutil.Factory
	Mapper        meta.RESTMapper
	CoreClient    kubernetes.Interface
	DynamicClient dynamic.Interface
}

func NewKubernetesClient

func NewKubernetesClient() (*KubernetesClient, error)

func (*KubernetesClient) Apply

func (client *KubernetesClient) Apply(
	documents []string,
	applySetParentName string,
	applySetParentNamespace string,
	skipConfirmation bool,
	forceConflicts bool,
	timeout time.Duration,
) error

func (*KubernetesClient) Delete

func (client *KubernetesClient) Delete(
	applySetParentName string,
	applySetParentNamespace string,
	skipConfirmation bool,
) error

func (*KubernetesClient) GetClusterInfo

func (client *KubernetesClient) GetClusterInfo() (*ClusterInfo, error)

func (*KubernetesClient) List

func (client *KubernetesClient) List(applySetParentNamespace string) error

func (*KubernetesClient) Wait

func (client *KubernetesClient) Wait(objects object.ObjMetadataSet, status status.Status, timeout time.Duration) error

func (*KubernetesClient) WaitDocuments

func (client *KubernetesClient) WaitDocuments(documents []string, sts status.Status, timeout time.Duration) error

type NoChangesError

type NoChangesError struct{}

func (NoChangesError) Error

func (e NoChangesError) Error() string

Jump to

Keyboard shortcuts

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