Skip to content

Commit

Permalink
Revert "feat: Remove ClusterRole (#169)"
Browse files Browse the repository at this point in the history
This reverts commit 2c53130.
  • Loading branch information
BeryJu committed Jul 13, 2023
1 parent 7f13cc6 commit 0c8957e
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: {{ include "authentik-remote-cluster.fullname" . }}-{{ .Release.Namespace }}
labels:
{{- include "authentik-remote-cluster.labels" . | nindent 4 }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ include "authentik-remote-cluster.fullname" . }}-{{ .Release.Namespace }}
subjects:
- kind: ServiceAccount
name: {{ include "authentik-remote-cluster.fullname" . }}
namespace: {{ .Release.Namespace }}
18 changes: 18 additions & 0 deletions charts/authentik-remote-cluster/templates/cluster-role.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: {{ include "authentik-remote-cluster.fullname" . }}-{{ .Release.Namespace }}
labels:
{{- include "authentik-remote-cluster.labels" . | nindent 4 }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
rules:
- apiGroups:
- apiextensions.k8s.io
resources:
- customresourcedefinitions
verbs:
- list

0 comments on commit 0c8957e

Please sign in to comment.