controllertools

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2023 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigMapControlInterface added in v1.6.0

type ConfigMapControlInterface interface {
	PatchConfigMap(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type ConfigMapControllerRefManager added in v1.6.0

type ConfigMapControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	ConfigMapControl ConfigMapControlInterface
	// contains filtered or unexported fields
}

func NewConfigMapControllerRefManager added in v1.6.0

func NewConfigMapControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	ConfigMapControl ConfigMapControlInterface,
) *ConfigMapControllerRefManager

func (*ConfigMapControllerRefManager) AdoptConfigMap added in v1.6.0

func (m *ConfigMapControllerRefManager) AdoptConfigMap(configMap *corev1.ConfigMap) error

func (*ConfigMapControllerRefManager) ClaimConfigMaps added in v1.6.0

func (m *ConfigMapControllerRefManager) ClaimConfigMaps(configMaps []*corev1.ConfigMap) (map[string]*corev1.ConfigMap, error)

func (*ConfigMapControllerRefManager) ReleaseConfigMap added in v1.6.0

func (m *ConfigMapControllerRefManager) ReleaseConfigMap(configMap *corev1.ConfigMap) error

type DaemonSetControlInterface added in v1.6.0

type DaemonSetControlInterface interface {
	PatchDaemonSet(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type DaemonSetControllerRefManager added in v1.6.0

type DaemonSetControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	DaemonSetControl DaemonSetControlInterface
	// contains filtered or unexported fields
}

func NewDaemonSetControllerRefManager added in v1.6.0

func NewDaemonSetControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	DaemonSetControl DaemonSetControlInterface,
) *DaemonSetControllerRefManager

func (*DaemonSetControllerRefManager) AdoptDaemonSet added in v1.6.0

func (m *DaemonSetControllerRefManager) AdoptDaemonSet(daemonset *appsv1.DaemonSet) error

func (*DaemonSetControllerRefManager) ClaimDaemonSets added in v1.6.0

func (m *DaemonSetControllerRefManager) ClaimDaemonSets(daemonsets []*appsv1.DaemonSet) (map[string]*appsv1.DaemonSet, error)

func (*DaemonSetControllerRefManager) ReleaseDaemonSet added in v1.6.0

func (m *DaemonSetControllerRefManager) ReleaseDaemonSet(daemonset *appsv1.DaemonSet) error

type IngressControlInterface added in v1.8.0

type IngressControlInterface interface {
	PatchIngress(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type IngressControllerRefManager added in v1.8.0

type IngressControllerRefManager struct {
	kubecontroller.BaseControllerRefManager
	// contains filtered or unexported fields
}

func NewIngressControllerRefManager added in v1.8.0

func NewIngressControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	IngressControl IngressControlInterface,
) *IngressControllerRefManager

func (*IngressControllerRefManager) AdoptIngress added in v1.8.0

func (m *IngressControllerRefManager) AdoptIngress(ingress *networkingv1.Ingress) error

func (*IngressControllerRefManager) ClaimIngresss added in v1.8.0

func (m *IngressControllerRefManager) ClaimIngresss(ingresses []*networkingv1.Ingress) (map[string]*networkingv1.Ingress, error)

func (*IngressControllerRefManager) ReleaseIngress added in v1.8.0

func (m *IngressControllerRefManager) ReleaseIngress(ingress *networkingv1.Ingress) error

type JobControlInterface added in v1.6.0

type JobControlInterface interface {
	PatchJob(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type JobControllerRefManager added in v1.6.0

type JobControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	JobControl JobControlInterface
	// contains filtered or unexported fields
}

func NewJobControllerRefManager added in v1.6.0

func NewJobControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	JobControl JobControlInterface,
) *JobControllerRefManager

func (*JobControllerRefManager) AdoptJob added in v1.6.0

func (m *JobControllerRefManager) AdoptJob(job *batchv1.Job) error

func (*JobControllerRefManager) ClaimJobs added in v1.6.0

func (m *JobControllerRefManager) ClaimJobs(jobs []*batchv1.Job) (map[string]*batchv1.Job, error)

func (*JobControllerRefManager) ReleaseJob added in v1.6.0

func (m *JobControllerRefManager) ReleaseJob(job *batchv1.Job) error

type PodDisruptionBudgetControlInterface

type PodDisruptionBudgetControlInterface interface {
	PatchPodDisruptionBudget(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type PodDisruptionBudgetControllerRefManager

type PodDisruptionBudgetControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	PodDisruptionBudgetControl PodDisruptionBudgetControlInterface
	// contains filtered or unexported fields
}

func NewPodDisruptionBudgetControllerRefManager

func NewPodDisruptionBudgetControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	PodDisruptionBudgetControl PodDisruptionBudgetControlInterface,
) *PodDisruptionBudgetControllerRefManager

func (*PodDisruptionBudgetControllerRefManager) AdoptPodDisruptionBudget

func (m *PodDisruptionBudgetControllerRefManager) AdoptPodDisruptionBudget(podDisruptionBudget *policyv1.PodDisruptionBudget) error

func (*PodDisruptionBudgetControllerRefManager) ClaimPodDisruptionBudgets

func (m *PodDisruptionBudgetControllerRefManager) ClaimPodDisruptionBudgets(podDisruptionBudgets []*policyv1.PodDisruptionBudget) (map[string]*policyv1.PodDisruptionBudget, error)

func (*PodDisruptionBudgetControllerRefManager) ReleasePodDisruptionBudget

func (m *PodDisruptionBudgetControllerRefManager) ReleasePodDisruptionBudget(podDisruptionBudget *policyv1.PodDisruptionBudget) error

type RealConfigMapControl added in v1.6.0

type RealConfigMapControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealConfigMapControl) PatchConfigMap added in v1.6.0

func (r RealConfigMapControl) PatchConfigMap(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealDaemonSetControl added in v1.6.0

type RealDaemonSetControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealDaemonSetControl) PatchDaemonSet added in v1.6.0

func (r RealDaemonSetControl) PatchDaemonSet(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealIngressControl added in v1.8.0

type RealIngressControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealIngressControl) PatchIngress added in v1.8.0

func (r RealIngressControl) PatchIngress(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealJobControl added in v1.6.0

type RealJobControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealJobControl) PatchJob added in v1.6.0

func (r RealJobControl) PatchJob(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealPodDisruptionBudgetControl

type RealPodDisruptionBudgetControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealPodDisruptionBudgetControl) PatchPodDisruptionBudget

func (r RealPodDisruptionBudgetControl) PatchPodDisruptionBudget(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealRoleBindingControl added in v1.8.0

type RealRoleBindingControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealRoleBindingControl) PatchRoleBinding added in v1.8.0

func (r RealRoleBindingControl) PatchRoleBinding(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealSecretControl

type RealSecretControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealSecretControl) PatchSecret

func (r RealSecretControl) PatchSecret(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealServiceAccountControl added in v1.8.0

type RealServiceAccountControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealServiceAccountControl) PatchServiceAccount added in v1.8.0

func (r RealServiceAccountControl) PatchServiceAccount(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealServiceControl

type RealServiceControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealServiceControl) PatchService

func (r RealServiceControl) PatchService(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RealStatefulSetControl

type RealStatefulSetControl struct {
	KubeClient kubernetes.Interface
	Recorder   record.EventRecorder
}

func (RealStatefulSetControl) PatchStatefulSet

func (r RealStatefulSetControl) PatchStatefulSet(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error

type RoleBindingControlInterface added in v1.8.0

type RoleBindingControlInterface interface {
	PatchRoleBinding(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type RoleBindingControllerRefManager added in v1.8.0

type RoleBindingControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	RoleBindingControl RoleBindingControlInterface
	// contains filtered or unexported fields
}

func NewRoleBindingControllerRefManager added in v1.8.0

func NewRoleBindingControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	RoleBindingControl RoleBindingControlInterface,
) *RoleBindingControllerRefManager

func (*RoleBindingControllerRefManager) AdoptRoleBinding added in v1.8.0

func (m *RoleBindingControllerRefManager) AdoptRoleBinding(roleBinding *rbacv1.RoleBinding) error

func (*RoleBindingControllerRefManager) ClaimRoleBindings added in v1.8.0

func (m *RoleBindingControllerRefManager) ClaimRoleBindings(roleBindings []*rbacv1.RoleBinding) (map[string]*rbacv1.RoleBinding, error)

func (*RoleBindingControllerRefManager) ReleaseRoleBinding added in v1.8.0

func (m *RoleBindingControllerRefManager) ReleaseRoleBinding(roleBinding *rbacv1.RoleBinding) error

type SecretControlInterface

type SecretControlInterface interface {
	PatchSecret(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type SecretControllerRefManager

type SecretControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	SecretControl SecretControlInterface
	// contains filtered or unexported fields
}

func NewSecretControllerRefManager

func NewSecretControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	SecretControl SecretControlInterface,
) *SecretControllerRefManager

func (*SecretControllerRefManager) AdoptSecret

func (m *SecretControllerRefManager) AdoptSecret(secret *corev1.Secret) error

func (*SecretControllerRefManager) ClaimSecrets

func (m *SecretControllerRefManager) ClaimSecrets(secrets []*corev1.Secret) (map[string]*corev1.Secret, error)

func (*SecretControllerRefManager) ReleaseSecret

func (m *SecretControllerRefManager) ReleaseSecret(secret *corev1.Secret) error

type ServiceAccountControlInterface added in v1.8.0

type ServiceAccountControlInterface interface {
	PatchServiceAccount(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type ServiceAccountControllerRefManager added in v1.8.0

type ServiceAccountControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	ServiceAccountControl ServiceAccountControlInterface
	// contains filtered or unexported fields
}

func NewServiceAccountControllerRefManager added in v1.8.0

func NewServiceAccountControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	ServiceAccountControl ServiceAccountControlInterface,
) *ServiceAccountControllerRefManager

func (*ServiceAccountControllerRefManager) AdoptServiceAccount added in v1.8.0

func (m *ServiceAccountControllerRefManager) AdoptServiceAccount(serviceAccount *corev1.ServiceAccount) error

func (*ServiceAccountControllerRefManager) ClaimServiceAccounts added in v1.8.0

func (m *ServiceAccountControllerRefManager) ClaimServiceAccounts(serviceAccounts []*corev1.ServiceAccount) (map[string]*corev1.ServiceAccount, error)

func (*ServiceAccountControllerRefManager) ReleaseServiceAccount added in v1.8.0

func (m *ServiceAccountControllerRefManager) ReleaseServiceAccount(serviceAccount *corev1.ServiceAccount) error

type ServiceControlInterface

type ServiceControlInterface interface {
	PatchService(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type ServiceControllerRefManager

type ServiceControllerRefManager struct {
	kubecontroller.BaseControllerRefManager

	ServiceControl ServiceControlInterface
	// contains filtered or unexported fields
}

func NewServiceControllerRefManager

func NewServiceControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	ServiceControl ServiceControlInterface,
) *ServiceControllerRefManager

func (*ServiceControllerRefManager) AdoptService

func (m *ServiceControllerRefManager) AdoptService(service *corev1.Service) error

func (*ServiceControllerRefManager) ClaimServices

func (m *ServiceControllerRefManager) ClaimServices(services []*corev1.Service) (map[string]*corev1.Service, error)

func (*ServiceControllerRefManager) ReleaseService

func (m *ServiceControllerRefManager) ReleaseService(service *corev1.Service) error

type StatefulSetControlInterface

type StatefulSetControlInterface interface {
	PatchStatefulSet(ctx context.Context, namespace, name string, pt types.PatchType, data []byte, options metav1.PatchOptions) error
}

type StatefulSetControllerRefManager

type StatefulSetControllerRefManager struct {
	kubecontroller.BaseControllerRefManager
	// contains filtered or unexported fields
}

func NewStatefulSetControllerRefManager

func NewStatefulSetControllerRefManager(
	ctx context.Context,
	controller metav1.Object,
	controllerGVK schema.GroupVersionKind,
	selector labels.Selector,
	canAdopt func() error,
	statefulSetControl StatefulSetControlInterface,
) *StatefulSetControllerRefManager

func (*StatefulSetControllerRefManager) AdoptStatefulSet

func (m *StatefulSetControllerRefManager) AdoptStatefulSet(statefulSet *appsv1.StatefulSet) error

func (*StatefulSetControllerRefManager) ClaimStatefulSets

func (m *StatefulSetControllerRefManager) ClaimStatefulSets(sets []*appsv1.StatefulSet) (map[string]*appsv1.StatefulSet, error)

func (*StatefulSetControllerRefManager) ReleaseStatefulSet

func (m *StatefulSetControllerRefManager) ReleaseStatefulSet(statefulSet *appsv1.StatefulSet) error

Jump to

Keyboard shortcuts

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