resourceapply

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: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyClusterRole added in v1.6.0

func ApplyClusterRole(
	ctx context.Context,
	client rbacv1client.ClusterRolesGetter,
	lister rbacv1listers.ClusterRoleLister,
	recorder record.EventRecorder,
	required *rbacv1.ClusterRole,
	allowMissingControllerRef bool,
) (*rbacv1.ClusterRole, bool, error)

ApplyClusterRole will apply the ClusterRole to match the required object.

func ApplyClusterRoleBinding added in v1.6.0

func ApplyClusterRoleBinding(
	ctx context.Context,
	client rbacv1client.ClusterRoleBindingsGetter,
	lister rbacv1listers.ClusterRoleBindingLister,
	recorder record.EventRecorder,
	required *rbacv1.ClusterRoleBinding,
	allowMissingControllerRef bool,
) (*rbacv1.ClusterRoleBinding, bool, error)

ApplyClusterRoleBinding will apply the ClusterRoleBinding to match the required object.

func ApplyConfigMap added in v1.6.0

ApplyConfigMap will apply the ConfigMap to match the required object.

func ApplyDaemonSet added in v1.6.0

func ApplyDaemonSet(
	ctx context.Context,
	client appv1client.DaemonSetsGetter,
	lister appv1listers.DaemonSetLister,
	recorder record.EventRecorder,
	required *appsv1.DaemonSet,
) (*appsv1.DaemonSet, bool, error)

ApplyDaemonSet will apply the DaemonSet to match the required object.

func ApplyIngress added in v1.8.0

ApplyIngress will apply the Ingress to match the required object.

func ApplyJob added in v1.6.0

func ApplyJob(
	ctx context.Context,
	client batchv1client.JobsGetter,
	lister batchv1listers.JobLister,
	recorder record.EventRecorder,
	required *batchv1.Job,
) (*batchv1.Job, bool, error)

ApplyJob will apply the Job to match the required object. forceOwnership allows to apply objects without an ownerReference. Normally such objects would be adopted but the old objects may not have correct labels that we need to fix in the new version.

func ApplyNamespace added in v1.6.0

func ApplyNamespace(
	ctx context.Context,
	client corev1client.NamespacesGetter,
	lister corev1listers.NamespaceLister,
	recorder record.EventRecorder,
	required *corev1.Namespace,
	allowMissingControllerRef bool,
) (*corev1.Namespace, bool, error)

ApplyNamespace will apply the Namespace to match the required object.

func ApplyPodDisruptionBudget

ApplyPodDisruptionBudget will apply the PodDisruptionBudget to match the required object. forceOwnership allows to apply objects without an ownerReference. Normally such objects would be adopted but the old objects may not have correct labels that we need to fix in the new version.

func ApplyRoleBinding added in v1.8.0

func ApplyRoleBinding(
	ctx context.Context,
	client rbacv1client.RoleBindingsGetter,
	lister rbacv1listers.RoleBindingLister,
	recorder record.EventRecorder,
	required *rbacv1.RoleBinding,
	forceOwnership bool,
	allowMissingControllerRef bool,
) (*rbacv1.RoleBinding, bool, error)

ApplyRoleBinding will apply the RoleBinding to match the required object.

func ApplySecret

func ApplySecret(
	ctx context.Context,
	client corev1client.SecretsGetter,
	lister corev1listers.SecretLister,
	recorder record.EventRecorder,
	required *corev1.Secret,
	forceOwnership bool,
) (*corev1.Secret, bool, error)

ApplySecret will apply the Secret to match the required object. forceOwnership allows to apply objects without an ownerReference. Normally such objects would be adopted but the old objects may not have correct labels that we need to fix in the new version.

func ApplyService

func ApplyService(
	ctx context.Context,
	client corev1client.ServicesGetter,
	lister corev1listers.ServiceLister,
	recorder record.EventRecorder,
	required *corev1.Service,
	forceOwnership bool,
) (*corev1.Service, bool, error)

ApplyService will apply the Service to match the required object. forceOwnership allows to apply objects without an ownerReference. Normally such objects would be adopted but the old objects may not have correct labels that we need to fix in the new version.

func ApplyServiceAccount added in v1.6.0

func ApplyServiceAccount(
	ctx context.Context,
	client corev1client.ServiceAccountsGetter,
	lister corev1listers.ServiceAccountLister,
	recorder record.EventRecorder,
	required *corev1.ServiceAccount,
	forceOwnership bool,
	allowMissingControllerRef bool,
) (*corev1.ServiceAccount, bool, error)

ApplyServiceAccount will apply the ServiceAccount to match the required object.

func ApplyStatefulSet

func ApplyStatefulSet(
	ctx context.Context,
	client appv1client.StatefulSetsGetter,
	lister appv1listers.StatefulSetLister,
	recorder record.EventRecorder,
	required *appsv1.StatefulSet,
	forceOwnership bool,
) (*appsv1.StatefulSet, bool, error)

ApplyStatefulSet will apply the StatefulSet to match the required object. forceOwnership allows to apply objects without an ownerReference. Normally such objects would be adopted but the old objects may not have correct labels that we need to fix in the new version.

func ReportCreateEvent

func ReportCreateEvent(recorder record.EventRecorder, obj runtime.Object, operationErr error)

func ReportDeleteEvent

func ReportDeleteEvent(recorder record.EventRecorder, obj runtime.Object, operationErr error)

func ReportUpdateEvent

func ReportUpdateEvent(recorder record.EventRecorder, obj runtime.Object, operationErr error)

func SetHashAnnotation

func SetHashAnnotation(obj metav1.Object) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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