From 61557bbe9a350abcc2ea2a0c18ed79a74085df0d Mon Sep 17 00:00:00 2001 From: Leonardo Luz Almeida Date: Tue, 15 Oct 2024 15:11:50 -0400 Subject: [PATCH] fix: set proper argocd resources in roles (#39) Signed-off-by: Leonardo Luz Almeida --- config/backend/role.yaml | 4 ++-- config/rbac/role.yaml | 4 ++-- internal/controller/accessrequest_controller.go | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/config/backend/role.yaml b/config/backend/role.yaml index e0cf3bc..4b89f22 100644 --- a/config/backend/role.yaml +++ b/config/backend/role.yaml @@ -11,13 +11,13 @@ rules: - apiGroups: - argoproj.io resources: - - application + - applications verbs: - get - apiGroups: - argoproj.io resources: - - appproject + - appprojects verbs: - get - apiGroups: diff --git a/config/rbac/role.yaml b/config/rbac/role.yaml index b0436eb..2ff1f51 100644 --- a/config/rbac/role.yaml +++ b/config/rbac/role.yaml @@ -7,13 +7,13 @@ rules: - apiGroups: - argoproj.io resources: - - application + - applications verbs: - get - apiGroups: - argoproj.io resources: - - appproject + - appprojects verbs: - get - list diff --git a/internal/controller/accessrequest_controller.go b/internal/controller/accessrequest_controller.go index 1079651..5a82f37 100644 --- a/internal/controller/accessrequest_controller.go +++ b/internal/controller/accessrequest_controller.go @@ -67,8 +67,8 @@ const ( // +kubebuilder:rbac:groups=ephemeral-access.argoproj-labs.io,resources=roletemplates,verbs=get;list;watch // +kubebuilder:rbac:groups=ephemeral-access.argoproj-labs.io,resources=roletemplates/status,verbs=get;update;patch // +kubebuilder:rbac:groups=ephemeral-access.argoproj-labs.io,resources=roletemplates/finalizers,verbs=update -// +kubebuilder:rbac:groups=argoproj.io,resources=appproject,verbs=get;list;watch;update;patch -// +kubebuilder:rbac:groups=argoproj.io,resources=application,verbs=get +// +kubebuilder:rbac:groups=argoproj.io,resources=appprojects,verbs=get;list;watch;update;patch +// +kubebuilder:rbac:groups=argoproj.io,resources=applications,verbs=get // Reconcile is the main function that will be invoked on every change in // AccessRequests desired state. It will: