From 6f34933803e693bc2cbc82e5ba9f4f51a8854a95 Mon Sep 17 00:00:00 2001 From: samdulam Date: Mon, 8 Apr 2024 15:28:19 +0530 Subject: [PATCH] add periodSeconds:30 to liveness and readiness probes (#142) * add periodSeconds:30 to liveness and readiness probes to stop pod from restarting before its ready. * change feature flags to an array and adjust the template * change feature.flags to list * fix template * use range instead of toyaml so we can use squote * increase probe times to 5 --- charts/portainer/Chart.yaml | 2 +- charts/portainer/templates/deployment.yaml | 10 ++++++---- charts/portainer/values.yaml | 2 +- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/charts/portainer/Chart.yaml b/charts/portainer/Chart.yaml index aa44678..21bdc2d 100644 --- a/charts/portainer/Chart.yaml +++ b/charts/portainer/Chart.yaml @@ -17,7 +17,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. -version: 1.0.49 +version: 1.0.50 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. diff --git a/charts/portainer/templates/deployment.yaml b/charts/portainer/templates/deployment.yaml index 67b59b5..b1dbbad 100644 --- a/charts/portainer/templates/deployment.yaml +++ b/charts/portainer/templates/deployment.yaml @@ -65,8 +65,8 @@ spec: {{- if (and (eq .Values.service.type "NodePort") (not (empty .Values.service.edgeNodePort))) }} - '--tunnel-port={{ .Values.service.edgeNodePort }}' {{- end }} - {{- if (not (empty .Values.feature.flags)) }} - - '{{ .Values.feature.flags }}' + {{- range .Values.feature.flags }} + - {{ . | squote }} {{- end }} volumeMounts: {{- if .Values.persistence.enabled }} @@ -96,8 +96,9 @@ spec: containerPort: 8000 protocol: TCP livenessProbe: - failureThreshold: 3 + failureThreshold: 5 initialDelaySeconds: 45 + periodSeconds: 30 httpGet: path: / {{- if .Values.tls.force }} @@ -143,8 +144,9 @@ spec: {{- end }} {{- end }} readinessProbe: - failureThreshold: 3 + failureThreshold: 5 initialDelaySeconds: 45 + periodSeconds: 30 httpGet: path: / {{- if .Values.tls.force }} diff --git a/charts/portainer/values.yaml b/charts/portainer/values.yaml index d878342..0d67a6e 100644 --- a/charts/portainer/values.yaml +++ b/charts/portainer/values.yaml @@ -51,7 +51,7 @@ mtls: existingSecret: "" feature: - flags: "" + flags: [] ingress: enabled: false