mirror of
https://github.com/truenas/charts.git
synced 2024-04-21 15:21:45 +00:00
somefixs
This commit is contained in:
@@ -79,9 +79,8 @@ tests:
|
||||
path: spec.jobTemplate.spec.template.spec.imagePullSecrets
|
||||
- isNull:
|
||||
path: spec.jobTemplate.spec.template.spec.runtimeClassName
|
||||
- equal:
|
||||
- isNull:
|
||||
path: spec.jobTemplate.spec.template.spec.terminationGracePeriodSeconds
|
||||
value: 10
|
||||
- equal:
|
||||
path: spec.jobTemplate.spec.template.spec.containers[0].name
|
||||
value: RELEASE-NAME-common-test-job-main
|
||||
|
||||
@@ -3,3 +3,16 @@ service:
|
||||
ports:
|
||||
main:
|
||||
port: 65535
|
||||
controllers:
|
||||
main:
|
||||
type: CronJob
|
||||
schedule: "* * * * *"
|
||||
pod:
|
||||
containers:
|
||||
main:
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
capabilities:
|
||||
add:
|
||||
- something
|
||||
|
||||
@@ -189,7 +189,7 @@
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- else -}} {{/* Otherwise use the job's podSecCont values (if empty, will use the global defaults) */}}
|
||||
{{- with (include "ix.v1.common.container.podSecurityContext" (dict "podSecCont" $values.podSecurityContext "root" $root "isJob" true) | trim) -}}
|
||||
{{- with (include "ix.v1.common.container.podSecurityContext" (dict "podSecCont" $root.Values.podSecurityContext "root" $root "isJob" true) | trim) -}}
|
||||
{{- $secCont = . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
|
||||
{{/* Add the .Values as the main container and as pod */}}
|
||||
{{/* This needs some redesign tbh */}}
|
||||
{{- $_ := set $jobValues "podSpec" (mustDeepCopy $.Values) -}}
|
||||
{{- $_ := set $jobValues "podSpec" (mustDeepCopy $.Values.controllers.main) -}}
|
||||
{{- $_ := set $jobValues.podSpec "containers" dict -}}
|
||||
{{- $_ := set $jobValues.podSpec.containers "main" .Values -}}
|
||||
{{- $_ := set $jobValues.podSpec.containers "main" .Values.controllers.main.pod.containers.main -}}
|
||||
{{- $_ := set $jobValues.podSpec.containers.main "enabled" "true" -}}
|
||||
|
||||
{{/* Add labels/annotations if any. */}}
|
||||
@@ -46,7 +46,6 @@
|
||||
{{- end -}}
|
||||
{{/* Add $jobValues to a "main" $job, now the spawner has the "usual" format */}}
|
||||
{{- $_ := set $jobs "main" $jobValues -}}
|
||||
|
||||
{{- else -}}
|
||||
|
||||
{{/* If it's not "standalone" Use the jobs dict */}}
|
||||
|
||||
Reference in New Issue
Block a user