From 04ff4e6e7e07670d31898d4235ce2b6580d70a5d Mon Sep 17 00:00:00 2001 From: Stavros kois Date: Mon, 13 Feb 2023 17:40:14 +0200 Subject: [PATCH] move another check --- .../common/1.0.0/templates/lib/container/_lifecycle.tpl | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/library/common/1.0.0/templates/lib/container/_lifecycle.tpl b/library/common/1.0.0/templates/lib/container/_lifecycle.tpl index 5863fce175..e385c43fe1 100644 --- a/library/common/1.0.0/templates/lib/container/_lifecycle.tpl +++ b/library/common/1.0.0/templates/lib/container/_lifecycle.tpl @@ -25,12 +25,9 @@ objectData: The object data to be used to render the container. {{- end }} {{ $hook }}: {{- if eq $hookValues.type "exec" -}} - {{- if not $hookValues.command -}} - {{- fail "Container - Expected non-empty on [exec] type" -}} - {{- end }} - {{- include "ix.v1.common.lib.container.actions.exec" (dict "rootCtx" $rootCtx "objectData" $hookValues) | trim | nindent 2 }} - {{- else if mustHas $hookValues.type (list "http" "https") }} - {{- include "ix.v1.common.lib.container.actions.httpGet" (dict "rootCtx" $rootCtx "objectData" $hookValues "caller" "lifecycle") | trim | nindent 2 }} + {{- include "ix.v1.common.lib.container.actions.exec" (dict "rootCtx" $rootCtx "objectData" $hookValues "caller" "lifecycle") | trim | nindent 2 -}} + {{- else if mustHas $hookValues.type (list "http" "https") -}} + {{- include "ix.v1.common.lib.container.actions.httpGet" (dict "rootCtx" $rootCtx "objectData" $hookValues "caller" "lifecycle") | trim | nindent 2 -}} {{- end -}} {{- end -}}