From c3aac9628d373ca723aeee58bee4439f2c9613f4 Mon Sep 17 00:00:00 2001 From: "SPEARS, DUSTIN (ds443n)" Date: Thu, 8 Feb 2024 15:03:20 -0500 Subject: [PATCH] Add liveness and readiness probe This adds liveness/readiness probes to sidecar for etcd Change-Id: If942de8b7c1a59e7da887e1bdc2626daf699aeab --- charts/etcd/templates/etc/_kubernetes-etcd.yaml.tpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/charts/etcd/templates/etc/_kubernetes-etcd.yaml.tpl b/charts/etcd/templates/etc/_kubernetes-etcd.yaml.tpl index aef76222..737f21ab 100644 --- a/charts/etcd/templates/etc/_kubernetes-etcd.yaml.tpl +++ b/charts/etcd/templates/etc/_kubernetes-etcd.yaml.tpl @@ -21,7 +21,6 @@ exec: - /bin/sh - -c - |- - export ETCDCTL_ENDPOINTS=https://$POD_IP:{{ .Values.network.service_client.target_port }} etcdctl endpoint health exit $? {{- end }} @@ -31,7 +30,6 @@ exec: - /bin/sh - -c - |- - export ETCDCTL_ENDPOINTS=https://$POD_IP:{{ .Values.network.service_client.target_port }} etcdctl endpoint status exit $? {{- end }} @@ -150,6 +148,8 @@ spec: value: "/etc/etcd/tls/etcd-client-key.pem" command: ["/bin/sh", "-c", "--"] args: ["while true; do sleep 30; done;"] +{{ dict "envAll" $envAll "component" "etcd" "container" "etcd" "type" "readiness" "probeTemplate" (include "etcdreadinessProbeTemplate" $envAll | fromYaml) | include "helm-toolkit.snippets.kubernetes_probe" | indent 6 }} +{{ dict "envAll" $envAll "component" "etcd" "container" "etcd" "type" "liveness" "probeTemplate" (include "etcdlivenessProbeTemplate" $envAll | fromYaml) | include "helm-toolkit.snippets.kubernetes_probe" | indent 6 }} volumeMounts: - name: etc mountPath: /etc/etcd