You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[](https://github.com/argoproj-labs/argocd-rbac-operator)
The Argo CD RBAC Operator provides a CRD based API for the RBAC management of Argo CD. It provides a structured and easy to use way to define RBAC policies. The Operator uses the CRs as a single source of truth for RBAC management and converts them into a policy string that is patched into the Argo CD RBAC ConfigMap.
12
+
The Argo CD RBAC Operator provides a CRD based API for the RBAC management of Argo CD. It provides a structured and easy to use way to define RBAC policies. The Operator uses the CRs as a single source of truth for RBAC management and converts them into a policy string that is patched into the Argo CD RBAC ConfigMap or AppProjects.
13
13
14
14
## Installation
15
15
@@ -64,6 +64,8 @@ helm install argocd-rbac-operator argocd-rbac-operator/argocd-rbac-operator -f v
64
64
65
65
## Usage
66
66
67
+
### Global-scoped RBAC
68
+
67
69
The following example shows a manifest to create a new ArgoCDRole `test-role`:
68
70
69
71
```yaml
@@ -105,7 +107,7 @@ spec:
105
107
name: "test-role"
106
108
```
107
109
108
-
### Create
110
+
#### Create ArgoCDRoles and ArgoCDRoleBindings
109
111
110
112
Make sure that the `argocd` Namespace exists, so that the ConfigMap can be created properly.
After the Resource is deleted, the policy string will be also deleted from the RBAC-CM.
154
156
155
-
### Change the Policy.CSV
157
+
#### Change the Policy.CSV
156
158
157
159
To change the policy.csv you have to make changes in the `internal/controller/common/defaults.go` file.
158
160
159
-
### Deployment types
161
+
#### Deployment types
160
162
161
163
As for now only single Argo CD deployment type is supported. The default Argo CD namespace is defined as `argocd`, to change that you have to provide a flag `--argocd-rbac-cm-namespace="your-argocd-namespace"`.
162
164
165
+
### AppProject-scoped RBAC
166
+
167
+
The following example shows a manifest to create a new ArgoCDProjectRole `test-project-role`:
#### Create ArgoCDProjectRoles and ArgoCDProjectRoleBindings
214
+
215
+
Create a new ArgoCDProjectRole and ArgoCDProjectRoleBinding using the provided example. (Make sure that both CRs and AppProjects are created in the same Namespace)
216
+
217
+
```bash
218
+
kubectl create -f test-project-role.yaml
219
+
kubectl create -f test-project-role-binding.yaml
220
+
```
221
+
222
+
After the reconciliation a following role will be added to the specified AppProjects:
223
+
224
+
```yaml
225
+
apiVersion: argoproj.io/v1alpha1
226
+
kind: AppProject
227
+
metadata:
228
+
name: test-appproject-1
229
+
namespace: test-ns
230
+
spec:
231
+
description: "Test AppProject 1 for ArgoCD's RBAC Operator"
0 commit comments