k8s

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2025 License: Apache-2.0 Imports: 10 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 {
	CreateSecret(ctx context.Context, name, namespace string, data map[string][]byte) error
	CreateConfigMap(ctx context.Context, name, namespace string, data map[string][]byte) error
}

Client is a client to mange worker Kubernetes resources.

type ClientFactory

type ClientFactory interface {
	NewClient(clusterID, token string) (Client, error)
	NewDynamicClient(clusterID, token string) (DynamicClient, error)
}

ClientFactory is a factory to create a Client.

func NewClientFactory

func NewClientFactory(endpoint string) ClientFactory

NewClientFactory creates a new ClientFactory.

type DynamicClient added in v1.5.0

type DynamicClient interface {
	PatchResource(ctx context.Context, name, namespace string, gvr schema.GroupVersionResource, data []byte) (*unstructured.Unstructured, error)
	DeleteResource(ctx context.Context, name, namespace string, gvr schema.GroupVersionResource) error
}

DynamicClient is a dynamic client to mange worker Kubernetes resources.

func NewDefaultDynamicClient added in v1.5.0

func NewDefaultDynamicClient(client dynamic.Interface) DynamicClient

NewDefaultDynamicClient creates a new DynamicClient.

Jump to

Keyboard shortcuts

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