Skip to content

Commit 2b21d0e

Browse files
authored
add cpfs.imagePullPrefix, remove nss roles (#2449)
* add cpfs.imagePullPrefix, remove nss roles Signed-off-by: Ben Luzarraga <luzarragaben@gmail.com> * add watch permissions to avoid noisy error message Signed-off-by: Ben Luzarraga <luzarragaben@gmail.com> --------- Signed-off-by: Ben Luzarraga <luzarragaben@gmail.com>
1 parent 6ab8fb7 commit 2b21d0e

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

bedrock-migration/templates/bedrock-migration-job.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ spec:
1212
spec:
1313
containers:
1414
- name: bedrock-migration-job
15-
image: {{ .Values.global.imagePullPrefix }}/{{ .Values.cpfs.imageRegistryNamespaceOperand }}/cpfs-utils:4.6.7
15+
image: {{ .Values.cpfs.imagePullPrefix | default .Values.global.imagePullPrefix }}/{{ .Values.cpfs.imageRegistryNamespaceOperand }}/cpfs-utils:4.6.7
1616
command:
1717
- bash
1818
- -c
@@ -113,6 +113,9 @@ spec:
113113
roles="${roles} $(oc get roles -n $ns | grep postgresql-operator-controller-manager | awk '{print $1}' | tr "\n" " ")"
114114
roles="${roles} $(oc get roles -n $ns | grep cloud-native-postgresql | awk '{print $1}' | tr "\n" " ")"
115115
roles="${roles} $(oc get roles -n $ns | grep common-service-db | awk '{print $1}' | tr "\n" " ")"
116+
117+
#get nss roles
118+
roles="${roles} $(oc get roles -n $ns | grep nss-managed-role-from | awk '{print $1}' | tr "\n" " ")"
116119
117120
if [[ $ns != $servicesNamespace ]]; then
118121
edbSA=$(oc get sa -n $ns --ignore-not-found | grep postgresql-operator-controller-manager | awk '{print $1}' | tr "\n" " ")

bedrock-migration/templates/rbac.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ rules:
2525
- list
2626
- get
2727
- delete
28+
- watch
2829
- apiGroups:
2930
- "rbac.authorization.k8s.io"
3031
resources:
@@ -34,6 +35,7 @@ rules:
3435
- list
3536
- get
3637
- delete
38+
- watch
3739
- apiGroups:
3840
- ""
3941
resources:
@@ -44,6 +46,7 @@ rules:
4446
- list
4547
- get
4648
- delete
49+
- watch
4750
- apiGroups:
4851
- "batch"
4952
resources:
@@ -52,6 +55,7 @@ rules:
5255
- list
5356
- get
5457
- delete
58+
- watch
5559
- apiGroups:
5660
- "operator.ibm.com"
5761
resources:
@@ -61,6 +65,7 @@ rules:
6165
- get
6266
- delete
6367
- patch
68+
- watch
6469
---
6570
kind: RoleBinding
6671
apiVersion: rbac.authorization.k8s.io/v1
@@ -102,6 +107,7 @@ rules:
102107
- list
103108
- get
104109
- delete
110+
- watch
105111
- apiGroups:
106112
- ""
107113
resources:
@@ -111,6 +117,7 @@ rules:
111117
- list
112118
- get
113119
- delete
120+
- watch
114121
---
115122
kind: RoleBinding
116123
apiVersion: rbac.authorization.k8s.io/v1

0 commit comments

Comments
 (0)