File tree Expand file tree Collapse file tree 3 files changed +76
-1
lines changed Expand file tree Collapse file tree 3 files changed +76
-1
lines changed Original file line number Diff line number Diff line change
1
+ {{ if .Values.rbac.createAggregateClusterRoles }}
2
+ apiVersion : rbac.authorization.k8s.io/v1
3
+ kind : ClusterRole
4
+ metadata :
5
+ labels :
6
+ rbac.authorization.k8s.io/aggregate-to-admin : " true"
7
+ app.kubernetes.io/name : {{ template "postgres-operator.name" . }}
8
+ helm.sh/chart : {{ template "postgres-operator.chart" . }}
9
+ app.kubernetes.io/managed-by : {{ .Release.Service }}
10
+ app.kubernetes.io/instance : {{ .Release.Name }}
11
+ name : {{ template "postgres-operator.fullname" . }}:users:admin
12
+ rules :
13
+ - apiGroups :
14
+ - acid.zalan.do
15
+ resources :
16
+ - postgresqls
17
+ - postgresqls/status
18
+ verbs :
19
+ - create
20
+ - delete
21
+ - deletecollection
22
+ - get
23
+ - list
24
+ - patch
25
+ - update
26
+ - watch
27
+
28
+ ---
29
+ apiVersion : rbac.authorization.k8s.io/v1
30
+ kind : ClusterRole
31
+ metadata :
32
+ labels :
33
+ rbac.authorization.k8s.io/aggregate-to-edit : " true"
34
+ app.kubernetes.io/name : {{ template "postgres-operator.name" . }}
35
+ helm.sh/chart : {{ template "postgres-operator.chart" . }}
36
+ app.kubernetes.io/managed-by : {{ .Release.Service }}
37
+ app.kubernetes.io/instance : {{ .Release.Name }}
38
+ name : {{ template "postgres-operator.fullname" . }}:users:edit
39
+ rules :
40
+ - apiGroups :
41
+ - acid.zalan.do
42
+ resources :
43
+ - postgresqls
44
+ verbs :
45
+ - create
46
+ - update
47
+ - patch
48
+ - delete
49
+
50
+ ---
51
+ apiVersion : rbac.authorization.k8s.io/v1
52
+ kind : ClusterRole
53
+ metadata :
54
+ labels :
55
+ rbac.authorization.k8s.io/aggregate-to-view : " true"
56
+ app.kubernetes.io/name : {{ template "postgres-operator.name" . }}
57
+ helm.sh/chart : {{ template "postgres-operator.chart" . }}
58
+ app.kubernetes.io/managed-by : {{ .Release.Service }}
59
+ app.kubernetes.io/instance : {{ .Release.Name }}
60
+ name : {{ template "postgres-operator.fullname" . }}:users:view
61
+ rules :
62
+ - apiGroups :
63
+ - acid.zalan.do
64
+ resources :
65
+ - postgresqls
66
+ - postgresqls/status
67
+ verbs :
68
+ - get
69
+ - list
70
+ - watch
71
+ {{ end }}
Original file line number Diff line number Diff line change @@ -361,6 +361,8 @@ configConnectionPooler:
361
361
rbac :
362
362
# Specifies whether RBAC resources should be created
363
363
create : true
364
+ # Specifies whether ClusterRoles that are aggregated into the K8s default roles should be created. (https://kubernetes.io/docs/reference/access-authn-authz/rbac/#default-roles-and-role-bindings)
365
+ createAggregateClusterRoles : false
364
366
365
367
serviceAccount :
366
368
# Specifies whether a ServiceAccount should be created
Original file line number Diff line number Diff line change @@ -291,6 +291,8 @@ kubectl create -f manifests/user-facing-clusterroles.yaml
291
291
It creates zalando-postgres-operator:user:view, :edit and :admin clusterroles
292
292
that are aggregated into the K8s [default roles](https://kubernetes.io/docs/reference/access-authn-authz/rbac/#default-roles-and-role-bindings).
293
293
294
+ For Helm deployments setting `rbac.createAggregateClusterRoles : true` adds these clusterroles to the deployment.
295
+
294
296
# # Use taints and tolerations for dedicated PostgreSQL nodes
295
297
296
298
To ensure Postgres pods are running on nodes without any other application pods,
@@ -762,7 +764,7 @@ WALE_S3_PREFIX=$WAL_S3_BUCKET/spilo/{WAL_BUCKET_SCOPE_PREFIX}{SCOPE}{WAL_BUCKET_
762
764
```
763
765
764
766
The operator sets the prefix to an empty string so that spilo will generate it
765
- from the configured ` WAL_S3_BUCKET ` .
767
+ from the configured ` WAL_S3_BUCKET ` .
766
768
767
769
:warning : When you overwrite the configuration by defining ` WAL_S3_BUCKET ` in
768
770
the [ pod_environment_configmap] ( #custom-pod-environment-variables ) you have
You can’t perform that action at this time.
0 commit comments