k8s

package
v17.6.0-rc5 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2024 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Get(ctx context.Context, gvr schema.GroupVersionResource, namespace, name string) (*unstructured.Unstructured, error)
	UpdateOrCreate(ctx context.Context, gvr schema.GroupVersionResource, namespace string, obj runtime.Object, force bool) (*unstructured.Unstructured, error)
	Delete(ctx context.Context, gvr schema.GroupVersionResource, namespace, name string) error
	Apply(ctx context.Context, config string) <-chan error
}

type K8sClient

type K8sClient struct {
	// contains filtered or unexported fields
}

func New

func New(log *slog.Logger, factory util.Factory) (*K8sClient, error)

func (*K8sClient) Apply

func (k *K8sClient) Apply(ctx context.Context, config string) <-chan error

func (*K8sClient) Delete added in v17.6.0

func (k *K8sClient) Delete(ctx context.Context, gvr schema.GroupVersionResource, namespace, name string) error

func (*K8sClient) Get added in v17.6.0

func (*K8sClient) UpdateOrCreate added in v17.6.0

func (k *K8sClient) UpdateOrCreate(ctx context.Context, gvr schema.GroupVersionResource, namespace string, obj runtime.Object, force bool) (*unstructured.Unstructured, error)

Jump to

Keyboard shortcuts

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