|
@@ -13,10 +13,17 @@ objectData:
|
|
{{- define "ix.v1.common.lib.workload.jobSpec" -}}
|
|
{{- define "ix.v1.common.lib.workload.jobSpec" -}}
|
|
{{- $objectData := .objectData -}}
|
|
{{- $objectData := .objectData -}}
|
|
{{- $rootCtx := .rootCtx -}}
|
|
{{- $rootCtx := .rootCtx -}}
|
|
|
|
+ {{- $parallelism := 1 -}}
|
|
|
|
+ {{- if hasKey $objectData "parallelism" -}}
|
|
|
|
+ {{- $parallelism = $objectData.parallelism -}}
|
|
|
|
+ {{- end -}}
|
|
|
|
+ {{- if (include "ix.v1.common.helper.isStopped" $rootCtx) -}}
|
|
|
|
+ {{- $parallelism = 0 -}}
|
|
|
|
+ {{- end }}
|
|
backoffLimit: {{ $objectData.backoffLimit | default 5 }}
|
|
backoffLimit: {{ $objectData.backoffLimit | default 5 }}
|
|
completionMode: {{ $objectData.completionMode | default "NonIndexed" }}
|
|
completionMode: {{ $objectData.completionMode | default "NonIndexed" }}
|
|
completions: {{ $objectData.completions | default nil }}
|
|
completions: {{ $objectData.completions | default nil }}
|
|
-parallelism: {{ $objectData.parallelism | default 1 }}
|
|
|
|
|
|
+parallelism: {{ $parallelism }}
|
|
ttlSecondsAfterFinished: {{ $objectData.ttlSecondsAfterFinished | default 120 }}
|
|
ttlSecondsAfterFinished: {{ $objectData.ttlSecondsAfterFinished | default 120 }}
|
|
{{- with $objectData.activeDeadlineSeconds }}
|
|
{{- with $objectData.activeDeadlineSeconds }}
|
|
activeDeadlineSeconds: {{ . }}
|
|
activeDeadlineSeconds: {{ . }}
|