[COMMON] Make imagePullSecrets configurable
[oom.git] / kubernetes / aai / components / aai-traversal / templates / job.yaml
index 1383997..687dcbf 100644 (file)
@@ -58,6 +58,13 @@ spec:
         image: {{ include "repositoryGenerator.image.readiness" . }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-readiness
+        resources:
+          limits:
+            cpu: "100m"
+            memory: "500Mi"
+          requests:
+            cpu: "3m"
+            memory: "20Mi"
       containers:
       - name: {{ include "common.name" . }}-job
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
@@ -106,6 +113,7 @@ spec:
           subPath: application.properties
         # disable liveness probe when breakpoints set in debugger
         # so K8s doesn't restart unresponsive container
+      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
       - name: localtime
         hostPath:
@@ -119,6 +127,5 @@ spec:
         configMap:
           name: {{ include "common.fullname" . }}
       restartPolicy: OnFailure
-      imagePullSecrets:
-      - name: "{{ include "common.namespace" . }}-docker-registry-key"
+      {{- include "common.imagePullSecrets" . | nindent 6 }}
 {{ end }}