From dfa8cd40702d00d38fc313ff68408ceecba68dd3 Mon Sep 17 00:00:00 2001 From: Orgad Shaneh Date: Wed, 21 Sep 2022 11:48:14 +0300 Subject: [PATCH] [bitnami/argo-workflows] Use custom probes if given (#12481) Without this change, in order to use a custom probe, the user has to specify the probe parameters, and also must specify for the original probe "enabled: false". Issue: #12354 Signed-off-by: Orgad Shaneh Signed-off-by: Orgad Shaneh --- bitnami/argo-workflows/Chart.yaml | 2 +- .../templates/controller/deployment.yaml | 18 +++++++++--------- .../templates/server/deployment.yaml | 18 +++++++++--------- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/bitnami/argo-workflows/Chart.yaml b/bitnami/argo-workflows/Chart.yaml index 79d38d645..b789041b5 100644 --- a/bitnami/argo-workflows/Chart.yaml +++ b/bitnami/argo-workflows/Chart.yaml @@ -35,4 +35,4 @@ sources: - https://github.com/bitnami/containers/tree/main/bitnami/argo-workflow-controller - https://github.com/bitnami/containers/tree/main/bitnami/argo-workflow-exec - https://argoproj.github.io/workflows/ -version: 2.4.3 +version: 2.4.4 diff --git a/bitnami/argo-workflows/templates/controller/deployment.yaml b/bitnami/argo-workflows/templates/controller/deployment.yaml index 93e6fe8d1..3b0821f2d 100644 --- a/bitnami/argo-workflows/templates/controller/deployment.yaml +++ b/bitnami/argo-workflows/templates/controller/deployment.yaml @@ -142,7 +142,9 @@ spec: {{- if .Values.controller.resources }} resources: {{- toYaml .Values.controller.resources | nindent 12 }} {{- end }} - {{- if .Values.controller.livenessProbe.enabled }} + {{- if .Values.controller.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customLivenessProbe "context" $) | nindent 12 }} + {{- else if .Values.controller.livenessProbe.enabled }} livenessProbe: tcpSocket: port: 6060 @@ -151,10 +153,10 @@ spec: timeoutSeconds: {{ .Values.controller.livenessProbe.timeoutSeconds }} successThreshold: {{ .Values.controller.livenessProbe.successThreshold }} failureThreshold: {{ .Values.controller.livenessProbe.failureThreshold }} - {{- else if .Values.controller.customLivenessProbe }} - livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customLivenessProbe "context" $) | nindent 12 }} {{- end }} - {{- if .Values.controller.readinessProbe.enabled }} + {{- if .Values.controller.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customReadinessProbe "context" $) | nindent 12 }} + {{- else if .Values.controller.readinessProbe.enabled }} readinessProbe: tcpSocket: port: 6060 @@ -163,10 +165,10 @@ spec: timeoutSeconds: {{ .Values.controller.readinessProbe.timeoutSeconds }} successThreshold: {{ .Values.controller.readinessProbe.successThreshold }} failureThreshold: {{ .Values.controller.readinessProbe.failureThreshold }} - {{- else if .Values.controller.customReadinessProbe }} - readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customReadinessProbe "context" $) | nindent 12 }} {{- end }} - {{- if .Values.controller.startupProbe.enabled }} + {{- if .Values.controller.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customStartupProbe "context" $) | nindent 12 }} + {{- else if .Values.controller.startupProbe.enabled }} startupProbe: httpGet: path: {{ .Values.controller.startupProbe.path }} @@ -176,8 +178,6 @@ spec: timeoutSeconds: {{ .Values.controller.startupProbe.timeoutSeconds }} successThreshold: {{ .Values.controller.startupProbe.successThreshold }} failureThreshold: {{ .Values.controller.startupProbe.failureThreshold }} - {{- else if .Values.controller.customStartupProbe }} - startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customStartupProbe "context" $) | nindent 12 }} {{- end }} {{- if .Values.controller.lifecycleHooks }} lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.controller.lifecycleHooks "context" $) | nindent 12 }} diff --git a/bitnami/argo-workflows/templates/server/deployment.yaml b/bitnami/argo-workflows/templates/server/deployment.yaml index b5f78a046..7c35fe248 100644 --- a/bitnami/argo-workflows/templates/server/deployment.yaml +++ b/bitnami/argo-workflows/templates/server/deployment.yaml @@ -133,7 +133,9 @@ spec: {{- if .Values.server.resources }} resources: {{- toYaml .Values.server.resources | nindent 12 }} {{- end }} - {{- if .Values.server.livenessProbe.enabled }} + {{- if .Values.server.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customLivenessProbe "context" $) | nindent 12 }} + {{- else if .Values.server.livenessProbe.enabled }} livenessProbe: httpGet: path: / @@ -146,10 +148,10 @@ spec: timeoutSeconds: {{ .Values.server.livenessProbe.timeoutSeconds }} successThreshold: {{ .Values.server.livenessProbe.successThreshold }} failureThreshold: {{ .Values.server.livenessProbe.failureThreshold }} - {{- else if .Values.server.customLivenessProbe }} - livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customLivenessProbe "context" $) | nindent 12 }} {{- end }} - {{- if .Values.server.readinessProbe.enabled }} + {{- if .Values.server.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customReadinessProbe "context" $) | nindent 12 }} + {{- else if .Values.server.readinessProbe.enabled }} readinessProbe: httpGet: path: / @@ -162,10 +164,10 @@ spec: timeoutSeconds: {{ .Values.server.readinessProbe.timeoutSeconds }} successThreshold: {{ .Values.server.readinessProbe.successThreshold }} failureThreshold: {{ .Values.server.readinessProbe.failureThreshold }} - {{- else if .Values.server.customReadinessProbe }} - readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customReadinessProbe "context" $) | nindent 12 }} {{- end }} - {{- if .Values.server.startupProbe.enabled }} + {{- if .Values.server.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customStartupProbe "context" $) | nindent 12 }} + {{- else if .Values.server.startupProbe.enabled }} startupProbe: httpGet: path: {{ .Values.server.startupProbe.path }} @@ -175,8 +177,6 @@ spec: timeoutSeconds: {{ .Values.server.startupProbe.timeoutSeconds }} successThreshold: {{ .Values.server.startupProbe.successThreshold }} failureThreshold: {{ .Values.server.startupProbe.failureThreshold }} - {{- else if .Values.server.customStartupProbe }} - startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customStartupProbe "context" $) | nindent 12 }} {{- end }} {{- if .Values.server.lifecycleHooks }} lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.server.lifecycleHooks "context" $) | nindent 12 }}