From 1827d88ca4aae4a678ab5cf7ee108c76bb9738a3 Mon Sep 17 00:00:00 2001 From: Alec Troemel Date: Sat, 10 Nov 2018 12:25:18 -0600 Subject: [PATCH] allow specification of update strategy on slaves (#9157) * allow specification of update strategy on slaves allow specification of update strategy on slaves, you should be able to specify stuff like maxUnavailable on slave updates. Otherwise, all your slaves may restart while the master is terminating/initializing. If this happens your slaves will be down just as long as the master Signed-off-by: Alec Troemel * version bump Signed-off-by: Alec Troemel * update docs Signed-off-by: Alec Troemel * remove trailing spaces Signed-off-by: Alec Troemel * remove extra paren Signed-off-by: Alec Troemel --- stable/redis/Chart.yaml | 2 +- stable/redis/templates/redis-slave-deployment.yaml | 4 ++++ stable/redis/values.yaml | 4 ++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/stable/redis/Chart.yaml b/stable/redis/Chart.yaml index a30a870856..87a0999dd8 100644 --- a/stable/redis/Chart.yaml +++ b/stable/redis/Chart.yaml @@ -1,5 +1,5 @@ name: redis -version: 4.2.8 +version: 4.2.9 appVersion: 4.0.11 description: Open source, advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets. keywords: diff --git a/stable/redis/templates/redis-slave-deployment.yaml b/stable/redis/templates/redis-slave-deployment.yaml index d587f55fc4..b5afd18831 100644 --- a/stable/redis/templates/redis-slave-deployment.yaml +++ b/stable/redis/templates/redis-slave-deployment.yaml @@ -9,6 +9,10 @@ metadata: release: "{{ .Release.Name }}" heritage: "{{ .Release.Service }}" spec: +{{- if .Values.slave.updateStrategy }} + strategy: +{{ toYaml .Values.slave.updateStrategy | indent 4 }} +{{- end }} {{- if .Values.cluster.slaveCount }} replicas: {{ .Values.cluster.slaveCount }} {{- end }} diff --git a/stable/redis/values.yaml b/stable/redis/values.yaml index f0ee04db25..0ceb1f17a0 100644 --- a/stable/redis/values.yaml +++ b/stable/redis/values.yaml @@ -245,6 +245,10 @@ slave: # extraFlags: [] ## Comma-separated list of Redis commands to disable # disableCommands: "" + ## deployment update stategy + # updateStrategy: + # rollingUpdate: + # maxUnavailable: 0 ## Redis Slave pod/node affinity/anti-affinity ##