From 6e556e592d5a183c764f3c27afbeaead0bf0dc9f Mon Sep 17 00:00:00 2001 From: Dinko Osrecki Date: Wed, 2 Jan 2019 13:32:15 +0100 Subject: [PATCH] [stable/redis] Process template directives in affinity parameters (#10312) * [stable/redis] Process template directives in affinity parameters Signed-off-by: Dinko Osrecki * [stable/redis] Update README Signed-off-by: Dinko Osrecki --- stable/redis/Chart.yaml | 2 +- stable/redis/README.md | 4 ++-- stable/redis/templates/redis-master-statefulset.yaml | 2 +- stable/redis/templates/redis-slave-deployment.yaml | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/stable/redis/Chart.yaml b/stable/redis/Chart.yaml index e8ed5acb06..c7f1a6a0ea 100644 --- a/stable/redis/Chart.yaml +++ b/stable/redis/Chart.yaml @@ -1,5 +1,5 @@ name: redis -version: 5.1.3 +version: 5.1.4 appVersion: 4.0.12 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/README.md b/stable/redis/README.md index 340c49f528..9c365d4411 100644 --- a/stable/redis/README.md +++ b/stable/redis/README.md @@ -141,7 +141,7 @@ The following table lists the configurable parameters of the Redis chart and the | `master.extraFlags` | Redis master additional command line flags | [] | | `master.nodeSelector` | Redis master Node labels for pod assignment | {"beta.kubernetes.io/arch": "amd64"} | | `master.tolerations` | Toleration labels for Redis master pod assignment | [] | -| `master.affinity ` | Affinity settings for Redis master pod assignment | [] | +| `master.affinity` | Affinity settings for Redis master pod assignment | {} | | `master.schedulerName` | Name of an alternate scheduler | `nil` | | `master.service.type` | Kubernetes Service type (redis master) | `ClusterIP` | | `master.service.port` | Kubernetes Service port (redis master) | `6379` | @@ -195,7 +195,7 @@ The following table lists the configurable parameters of the Redis chart and the | `slave.securityContext.fsGroup` | Group ID for the container (redis slave pod) | `master.securityContext.fsGroup` | | `slave.securityContext.runAsUser` | User ID for the container (redis slave pod) | `master.securityContext.runAsUser` | | `slave.resources` | Redis slave CPU/Memory resource requests/limits | `master.resources` | -| `slave.affinity` | Enable node/pod affinity for slaves | {} | +| `slave.affinity` | Affinity settings for Redis slave pod assignment | {} | Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, diff --git a/stable/redis/templates/redis-master-statefulset.yaml b/stable/redis/templates/redis-master-statefulset.yaml index 4424ce5195..2d269db603 100644 --- a/stable/redis/templates/redis-master-statefulset.yaml +++ b/stable/redis/templates/redis-master-statefulset.yaml @@ -46,7 +46,7 @@ spec: serviceAccountName: "{{ template "redis.serviceAccountName" . }}" {{- with .Values.master.affinity }} affinity: -{{ toYaml . | indent 8 }} +{{ tpl (toYaml .) $ | indent 8 }} {{- end }} {{- if .Values.master.nodeSelector }} nodeSelector: diff --git a/stable/redis/templates/redis-slave-deployment.yaml b/stable/redis/templates/redis-slave-deployment.yaml index ca8e1eadf4..8f6a1092b7 100644 --- a/stable/redis/templates/redis-slave-deployment.yaml +++ b/stable/redis/templates/redis-slave-deployment.yaml @@ -61,7 +61,7 @@ spec: {{- end }} {{- with .Values.slave.affinity }} affinity: -{{ toYaml . | indent 8 }} +{{ tpl (toYaml .) $ | indent 8 }} {{- end }} containers: - name: {{ template "redis.fullname" . }}