pkg

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2026 License: BSD-2-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CRDClientBuilder

type CRDClientBuilder func(*rest.Config) (apiextensionsclient.Interface, error)

CRDClientBuilder is the test seam for constructing the apiextensions clientset. Production wiring passes apiextensionsclient.NewForConfig; tests wire it to a closure that returns the fake clientset.

type ConfigBuilder

type ConfigBuilder func() (*rest.Config, error)

ConfigBuilder is the test seam for loading the rest.Config. Production wiring passes rest.InClusterConfig; tests pass a closure that returns a zero-value *rest.Config so SetupCustomResourceDefinition runs without a real in-cluster service-account token mount.

type K8sConnector

type K8sConnector interface {
	SetupCustomResourceDefinition(ctx context.Context) error
}

K8sConnector installs the Schedule CRD on a Kubernetes cluster.

func NewK8sConnector

func NewK8sConnector(configBuilder ConfigBuilder, clientBuilder CRDClientBuilder) K8sConnector

NewK8sConnector builds a connector that uses configBuilder to load the k8s config and clientBuilder to construct the apiextensions clientset. Production wiring passes rest.InClusterConfig + apiextensionsclient.NewForConfig; tests pass closures returning stubs/fakes.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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