From 12c78dea563533e053d0830b9f2525c34a9a464e Mon Sep 17 00:00:00 2001 From: Ehsan Date: Fri, 30 Aug 2024 16:51:25 +0000 Subject: [PATCH] Fix issue #107, Add WithManagementPolicies to the template for Reconciler Initialization --- hack/helpers/controller/KIND_LOWER/KIND_LOWER.go.tmpl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hack/helpers/controller/KIND_LOWER/KIND_LOWER.go.tmpl b/hack/helpers/controller/KIND_LOWER/KIND_LOWER.go.tmpl index 9ce8ada..257ab95 100644 --- a/hack/helpers/controller/KIND_LOWER/KIND_LOWER.go.tmpl +++ b/hack/helpers/controller/KIND_LOWER/KIND_LOWER.go.tmpl @@ -71,7 +71,8 @@ func Setup(mgr ctrl.Manager, o controller.Options) error { managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithPollInterval(o.PollInterval), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), - managed.WithConnectionPublishers(cps...)) + managed.WithConnectionPublishers(cps...), + managed.WithManagementPolicies()) return ctrl.NewControllerManagedBy(mgr). Named(name).