Skip to content

Commit

Permalink
fix(iom): use unique names for service accounts to enable running mul… (
Browse files Browse the repository at this point in the history
#55)

* fix(iom): use unique names for service accounts to enable running multiple IOMs in one namespace

* fix(iom): use unique names for service accounts to enable running multiple IOMs in one namespace

Co-authored-by: Andreas Herold <[email protected]>
  • Loading branch information
A-Herold and A-Herold committed Aug 12, 2022
1 parent 4e244b9 commit ecc5425
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
14 changes: 7 additions & 7 deletions charts/iom/templates/patch-downtime.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: iom-patch
name: {{ .Release.Name }}-iom-patch
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: iom-patch
name: {{ .Release.Name }}-iom-patch
rules:
- apiGroups:
- apps
Expand All @@ -20,14 +20,14 @@ rules:
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: iom-patch
name: {{ .Release.Name }}-iom-patch
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: iom-patch
name: {{ .Release.Name }}-iom-patch
subjects:
- kind: ServiceAccount
name: iom-patch
name: {{ .Release.Name }}-iom-patch
---
apiVersion: batch/v1
kind: Job
Expand All @@ -54,7 +54,7 @@ spec:
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
spec:
restartPolicy: Never
serviceAccountName: iom-patch
serviceAccountName: {{ .Release.Name }}-iom-patch
containers:
- name: patch-replica-count
image: "bitnami/kubectl"
Expand All @@ -67,4 +67,4 @@ spec:
- {{ .Release.Namespace }}
- -p
- '{"spec":{"replicas":{{ .Values.replicaCount }}}}'
{{- end }}
{{- end }}
12 changes: 6 additions & 6 deletions charts/iom/templates/patch-mailhog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: mailhog-patch
name: {{ .Release.Name }}-mailhog-patch
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: mailhog-patch
name: {{ .Release.Name }}-mailhog-patch
rules:
- apiGroups:
- apps
Expand All @@ -20,14 +20,14 @@ rules:
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: mailhog-patch
name: {{ .Release.Name }}-mailhog-patch
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: mailhog-patch
name: {{ .Release.Name }}-mailhog-patch
subjects:
- kind: ServiceAccount
name: mailhog-patch
name: {{ .Release.Name }}-mailhog-patch
---
apiVersion: batch/v1
kind: Job
Expand All @@ -54,7 +54,7 @@ spec:
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
spec:
restartPolicy: Never
serviceAccountName: mailhog-patch
serviceAccountName: {{ .Release.Name }}-mailhog-patch
containers:
- name: patch-mailhog-probes
image: "bitnami/kubectl"
Expand Down

0 comments on commit ecc5425

Please sign in to comment.