-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathvenafi-connection-rbac.yaml
More file actions
46 lines (44 loc) · 1.27 KB
/
venafi-connection-rbac.yaml
File metadata and controls
46 lines (44 loc) · 1.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{{- if .Values.venafiConnection.include }}
# The 'venafi-connection' service account is used by multiple
# controllers. When configuring which resources a VenafiConnection
# can access, the RBAC rules you create manually must point to this SA.
apiVersion: v1
kind: ServiceAccount
metadata:
name: venafi-connection
namespace: {{ $.Release.Namespace | quote }}
labels:
{{- include "venafi-connection.labels" $ | nindent 4 }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: venafi-connection-role
labels:
{{- include "venafi-connection.labels" $ | nindent 4 }}
rules:
- apiGroups: [ "" ]
resources: [ "namespaces" ]
verbs: [ "get", "list", "watch" ]
- apiGroups: [ "jetstack.io" ]
resources: [ "venaficonnections" ]
verbs: [ "get", "list", "watch" ]
- apiGroups: [ "jetstack.io" ]
resources: [ "venaficonnections/status" ]
verbs: [ "get", "patch" ]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: venafi-connection-rolebinding
labels:
{{- include "venafi-connection.labels" $ | nindent 4 }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: venafi-connection-role
subjects:
- kind: ServiceAccount
name: venafi-connection
namespace: {{ $.Release.Namespace | quote }}
{{- end }}