Code Review
/
oom.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
[OOM] Fixing k8s ServiceAccounts
[oom.git]
/
kubernetes
/
common
/
mariadb-init
/
templates
/
job.yaml
diff --git
a/kubernetes/common/mariadb-init/templates/job.yaml
b/kubernetes/common/mariadb-init/templates/job.yaml
index
96d1dc5
..
a899d93
100644
(file)
--- a/
kubernetes/common/mariadb-init/templates/job.yaml
+++ b/
kubernetes/common/mariadb-init/templates/job.yaml
@@
-59,6
+59,8
@@
spec:
- /bin/sh
- -c
- |
- /bin/sh
- -c
- |
+ {{- if include "common.onServiceMesh" . }}
+ echo "waiting 15s for istio side cars to be up"; sleep 15s;{{- end }}
/db_init/db_init.sh {{ if or .Values.dbScriptConfigMap .Values.dbScript }} &&
/db_config/db_cmd.sh{{ end }}
env:
/db_init/db_init.sh {{ if or .Values.dbScriptConfigMap .Values.dbScript }} &&
/db_config/db_cmd.sh{{ end }}
env:
@@
-89,8
+91,8
@@
spec:
- name: mariadb-conf
mountPath: /db_config/
{{- end }}
- name: mariadb-conf
mountPath: /db_config/
{{- end }}
- resources:
-
{{ include "common.resources" . | indent 12
}}
+ resources:
{{ include "common.resources" . | nindent 10 }}
+
{{ include "common.waitForJobContainer" . | indent 6 | trim
}}
{{- if .Values.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nodeSelector | indent 10 }}
{{- if .Values.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nodeSelector | indent 10 }}
@@
-99,6
+101,7
@@
spec:
affinity:
{{ toYaml .Values.affinity | indent 10 }}
{{- end }}
affinity:
{{ toYaml .Values.affinity | indent 10 }}
{{- end }}
+ serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
volumes:
- name: localtime
hostPath:
volumes:
- name: localtime
hostPath: