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 ¶
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 ¶
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.