From fb5779d63b07e8cadc37d83a4219354c4faf07e7 Mon Sep 17 00:00:00 2001 From: alexk <42849762+alexku7@users.noreply.github.com> Date: Sun, 20 Aug 2023 21:23:43 +0300 Subject: [PATCH] add minReadySeconds param to the helm chart deployment Signed-off-by: Kurtser Alex --- CHANGELOG.md | 2 +- chart/elastalert2/README.md | 1 + chart/elastalert2/templates/deployment.yaml | 1 + chart/elastalert2/values.yaml | 3 +++ 4 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 85eb535e..c888f740 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,7 @@ - TBD ## Other changes -- TBD +- [Helm] Expose minReadySeconds parameter to assist in detecting failed deployments - [#1243](https://github.com/jertel/elastalert2/pull/1243) - @alexku7 # 2.13.2 diff --git a/chart/elastalert2/README.md b/chart/elastalert2/README.md index beacc308..04b32071 100644 --- a/chart/elastalert2/README.md +++ b/chart/elastalert2/README.md @@ -58,6 +58,7 @@ The command removes all the Kubernetes components associated with the chart and | `command` | command override for container | `NULL` | | `args` | args override for container | `NULL` | | `replicaCount` | number of replicas to run | 1 | +| `minReadySeconds` | # number of seconds for which a newly created Pod should be ready without any of its containers crashing, for it to be considered available | 5 | | `rulesFolder` | Locaton of rules directory. Useful when you have one Docker image and different set of rules per environemnt. | /opt/elastalert/rules | | `elasticsearch.host` | elasticsearch endpoint to use | elasticsearch | | `elasticsearch.port` | elasticsearch port to use | 9200 | diff --git a/chart/elastalert2/templates/deployment.yaml b/chart/elastalert2/templates/deployment.yaml index f81bdd2e..e421de7d 100644 --- a/chart/elastalert2/templates/deployment.yaml +++ b/chart/elastalert2/templates/deployment.yaml @@ -16,6 +16,7 @@ spec: {{- include "common.labels.matchLabels" . | nindent 6 }} replicas: {{ .Values.replicaCount }} revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} + minReadySeconds: {{ .Values.minReadySeconds }} template: metadata: annotations: diff --git a/chart/elastalert2/values.yaml b/chart/elastalert2/values.yaml index b1b03229..f17f91eb 100644 --- a/chart/elastalert2/values.yaml +++ b/chart/elastalert2/values.yaml @@ -19,6 +19,9 @@ replicaCount: 1 # number of helm release revisions to retain revisionHistoryLimit: 5 +# number of seconds for which a newly created Pod should be ready without any of its containers crashing, for it to be considered available. +minReadySeconds: 5 + # Default internal between alert checks against the elasticsearch datasource, in minutes runIntervalMins: 1