From 5b2677400ec143e25f9c85936dcfcd95049625bb Mon Sep 17 00:00:00 2001 From: ubombar Date: Tue, 19 Mar 2024 15:52:56 +0100 Subject: [PATCH] Remove artifacts of selective deployments --- cmd/main.go | 12 --------- config/rbac/role.yaml | 61 +------------------------------------------ 2 files changed, 1 insertion(+), 72 deletions(-) diff --git a/cmd/main.go b/cmd/main.go index 3cc993a..9eb7f77 100644 --- a/cmd/main.go +++ b/cmd/main.go @@ -35,9 +35,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/webhook" antreav1alpha1 "antrea.io/antrea/pkg/apis/crd/v1alpha1" - deploymentsv1 "github.com/edgenet-project/edgenet-software/api/deployments/v1" multitenancyv1 "github.com/edgenet-project/edgenet-software/api/multitenancy/v1" - deploymentscontroller "github.com/edgenet-project/edgenet-software/internal/controller/deployments" multitenancycontroller "github.com/edgenet-project/edgenet-software/internal/controller/multitenancy" "github.com/edgenet-project/edgenet-software/internal/utils" //+kubebuilder:scaffold:imports @@ -53,7 +51,6 @@ func init() { utilruntime.Must(antreav1alpha1.AddToScheme(scheme)) utilruntime.Must(multitenancyv1.AddToScheme(scheme)) - utilruntime.Must(deploymentsv1.AddToScheme(scheme)) //+kubebuilder:scaffold:scheme } @@ -154,15 +151,6 @@ func main() { os.Exit(1) } } - if !disabledReconcilers.Contains("SelectiveDeployment") { - if err = (&deploymentscontroller.SelectiveDeploymentReconciler{ - Client: mgr.GetClient(), - Scheme: mgr.GetScheme(), - }).SetupWithManager(mgr); err != nil { - setupLog.Error(err, "unable to create controller", "controller", "SelectiveDeployment") - os.Exit(1) - } - } //+kubebuilder:scaffold:builder if err := mgr.AddHealthzCheck("healthz", healthz.Ping); err != nil { diff --git a/config/rbac/role.yaml b/config/rbac/role.yaml index f4e2db3..842ac0b 100644 --- a/config/rbac/role.yaml +++ b/config/rbac/role.yaml @@ -1,3 +1,4 @@ +--- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole metadata: @@ -15,66 +16,6 @@ rules: - patch - update - watch -- apiGroups: - - apps - resources: - - cronjobs - verbs: - - create - - delete - - get - - list - - patch - - update - - watch -- apiGroups: - - apps - resources: - - daemonsets - verbs: - - create - - delete - - get - - list - - patch - - update - - watch -- apiGroups: - - apps - resources: - - deployments - verbs: - - create - - delete - - get - - list - - patch - - update - - watch -- apiGroups: - - apps - resources: - - jobs - verbs: - - create - - delete - - get - - list - - patch - - update - - watch -- apiGroups: - - apps - resources: - - statefulsets - verbs: - - create - - delete - - get - - list - - patch - - update - - watch - apiGroups: - crd.antrea.io resources: