mirror of
https://github.com/bjw-s-labs/helm-charts.git
synced 2025-07-03 16:37:04 +02:00
feat(common): Release version 2.0.0-beta.1 (#173)
This commit is contained in:
parent
19767d668c
commit
7b6ee00be6
189 changed files with 3110 additions and 3023 deletions
|
@ -0,0 +1,28 @@
|
|||
{{- /*
|
||||
Returns the value for containers
|
||||
*/ -}}
|
||||
{{- define "bjw-s.common.lib.pod.field.containers" -}}
|
||||
{{- $rootContext := .ctx.rootContext -}}
|
||||
{{- $controllerObject := .ctx.controllerObject -}}
|
||||
|
||||
{{- /* Default to empty list */ -}}
|
||||
{{- $containers := list -}}
|
||||
|
||||
{{- /* Fetch configured containers for this controller */ -}}
|
||||
{{- $enabledContainers := include "bjw-s.common.lib.controller.enabledContainers" (dict "rootContext" $rootContext "controllerObject" $controllerObject) | fromYaml }}
|
||||
{{- range $key, $containerValues := $enabledContainers -}}
|
||||
{{- /* Create object from the container values */ -}}
|
||||
{{- $containerObject := (include "bjw-s.common.lib.container.valuesToObject" (dict "rootContext" $ "id" $key "values" $containerValues)) | fromYaml -}}
|
||||
|
||||
{{- /* Perform validations on the Container before rendering */ -}}
|
||||
{{- include "bjw-s.common.lib.container.validate" (dict "rootContext" $ "object" $containerObject) -}}
|
||||
|
||||
{{- /* Generate the Container spec */ -}}
|
||||
{{- $renderedContainer := include "bjw-s.common.lib.container.spec" (dict "rootContext" $rootContext "controllerObject" $controllerObject "containerObject" $containerObject) | fromYaml -}}
|
||||
{{- $containers = append $containers $renderedContainer -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if not (empty $containers) -}}
|
||||
{{- $containers | toYaml -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
Loading…
Add table
Add a link
Reference in a new issue