1+ # vim: set ft=helm :
12{{/*
23 * Copyright 2022 Open Ag Data Alliance
34 *
@@ -34,7 +35,6 @@ stringData:
3435{{- end }}
3536---
3637{{- $jobName := print "user-add-" .name "-" $.Release.Name -}}
37- {{- if empty (lookup "batch/v1" "Job" $.Release.Namespace $jobName) }}
3838apiVersion : batch/v1
3939kind : Job
4040metadata :
@@ -43,6 +43,12 @@ metadata:
4343 labels :
4444 app.kubernetes.io/component : init
4545 {{- include "oada.chart.labels" $ | nindent 4 }}
46+ annotations :
47+ # This is what defines this resource as a hook. Without this line, the
48+ # job is considered part of the release.
49+ " helm.sh/hook " : post-install
50+ # "helm.sh/hook": post-install,post-upgrade
51+ " helm.sh/hook-weight " : " 5"
4652spec :
4753 backoffLimit : 10
4854 template :
@@ -101,7 +107,7 @@ spec:
101107 - name : inspect
102108 containerPort : 9229
103109 {{- end }}
104- image : oada/ users:{{ $tag }}
110+ image : {{ $.Values. oada.namespace }} users:{{ $tag }}
105111 # imagePullPolicy: {{ $.Values.global.development | ternary "Always" "IfNotPresent" }}
106112 command :
107113 - /usr/bin/dumb-init
@@ -154,7 +160,7 @@ spec:
154160 - name : inspect
155161 containerPort : 9229
156162 {{- end }}
157- image : oada/ auth:{{ $tag }}
163+ image : {{ $.Values. oada.namespace }} auth:{{ $tag }}
158164 imagePullPolicy : {{ $.Values.oada.imagePullPolicy }}
159165 command : ["/usr/bin/dumb-init", "--rewrite", "15:2", "--", "/bin/sh"]
160166 args :
@@ -171,5 +177,4 @@ spec:
171177 allowPrivilegeEscalation : false
172178 readOnlyRootFilesystem : true
173179---
174- {{- end -}}
175180{{- end }}
0 commit comments