From ba9682d47ddc6e64b672793525448eb5ab50a32f Mon Sep 17 00:00:00 2001 From: Doris Zhou <53917499+doris-zhou@users.noreply.github.com> Date: Fri, 2 Feb 2024 10:51:29 -0500 Subject: [PATCH] [alertmanager] Add support for minReadySeconds (#4216) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * [alertmanager] Add support for minReadySeconds Signed-off-by: Doris Zhou * Update charts/alertmanager/templates/statefulset.yaml Co-authored-by: André Bauer Signed-off-by: Doris Zhou <53917499+doris-zhou@users.noreply.github.com> * Update charts/alertmanager/values.yaml Co-authored-by: André Bauer Signed-off-by: Doris Zhou <53917499+doris-zhou@users.noreply.github.com> --------- Signed-off-by: Doris Zhou Signed-off-by: Doris Zhou <53917499+doris-zhou@users.noreply.github.com> Co-authored-by: André Bauer --- charts/alertmanager/Chart.yaml | 2 +- charts/alertmanager/templates/statefulset.yaml | 1 + charts/alertmanager/values.yaml | 7 +++++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/charts/alertmanager/Chart.yaml b/charts/alertmanager/Chart.yaml index 4b0884111b8d..842cae8d7d01 100644 --- a/charts/alertmanager/Chart.yaml +++ b/charts/alertmanager/Chart.yaml @@ -6,7 +6,7 @@ icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/a sources: - https://github.com/prometheus/alertmanager type: application -version: 1.7.0 +version: 1.8.0 appVersion: v0.26.0 kubeVersion: ">=1.19.0-0" keywords: diff --git a/charts/alertmanager/templates/statefulset.yaml b/charts/alertmanager/templates/statefulset.yaml index 25d81a921345..807fd683988e 100644 --- a/charts/alertmanager/templates/statefulset.yaml +++ b/charts/alertmanager/templates/statefulset.yaml @@ -12,6 +12,7 @@ metadata: namespace: {{ include "alertmanager.namespace" . }} spec: replicas: {{ .Values.replicaCount }} + minReadySeconds: {{ .Values.minReadySeconds }} revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} selector: matchLabels: diff --git a/charts/alertmanager/values.yaml b/charts/alertmanager/values.yaml index fa3b355a5114..532ab9f6086d 100644 --- a/charts/alertmanager/values.yaml +++ b/charts/alertmanager/values.yaml @@ -235,6 +235,13 @@ topologySpreadConstraints: [] statefulSet: annotations: {} +## Minimum number of seconds for which a newly created pod should be ready without any of its container crashing for it to +## be considered available. Defaults to 0 (pod will be considered available as soon as it is ready). +## This is an alpha field from kubernetes 1.22 until 1.24 which requires enabling the StatefulSetMinReadySeconds +## feature gate. +## Ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#minimum-ready-seconds +minReadySeconds: 0 + podAnnotations: {} podLabels: {}