From bb716dfaca2ee5ba107a68c805c6e8d777da7af3 Mon Sep 17 00:00:00 2001 From: Igor Blackman Date: Wed, 13 May 2020 18:40:22 -0300 Subject: [PATCH] Enable option to specify a different strategy than recreate (#22387) Signed-off-by: Igor Valente Blackman --- stable/nextcloud/Chart.yaml | 2 +- stable/nextcloud/README.md | 1 + stable/nextcloud/templates/deployment.yaml | 2 +- stable/nextcloud/values.yaml | 10 ++++++++++ 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/stable/nextcloud/Chart.yaml b/stable/nextcloud/Chart.yaml index 14bdc90927..30a0cffdb3 100644 --- a/stable/nextcloud/Chart.yaml +++ b/stable/nextcloud/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: nextcloud -version: 1.10.0 +version: 1.10.1 appVersion: 17.0.0 description: A file sharing server that puts the control and security of your own data back into your hands. keywords: diff --git a/stable/nextcloud/README.md b/stable/nextcloud/README.md index 9236989c79..3a81c11e5a 100644 --- a/stable/nextcloud/README.md +++ b/stable/nextcloud/README.md @@ -81,6 +81,7 @@ The following table lists the configurable parameters of the nextcloud chart and | `nextcloud.defaultConfigs.\.apps\.config\.php` | Default configuration for apps | `true` | | `nextcloud.defaultConfigs.\.autoconfig\.php` | Default auto-configuration for databases | `true` | | `nextcloud.defaultConfigs.\.smtp\.config\.php` | Default configuration for smtp | `true` | +| `nextcloud.strategy` | specifies the strategy used to replace old Pods by new ones | `type: Recreate` | | `nextcloud.extraEnv` | specify additional environment variables | `{}` | | `nextcloud.extraVolumes` | specify additional volumes for the NextCloud pod | `{}` | | `nextcloud.extraVolumeMounts` | specify additional volume mounts for the NextCloud pod | `{}` | diff --git a/stable/nextcloud/templates/deployment.yaml b/stable/nextcloud/templates/deployment.yaml index 1709413020..3a395a435c 100644 --- a/stable/nextcloud/templates/deployment.yaml +++ b/stable/nextcloud/templates/deployment.yaml @@ -14,7 +14,7 @@ metadata: spec: replicas: {{ .Values.replicaCount }} strategy: - type: Recreate +{{ toYaml .Values.nextcloud.strategy | indent 4 }} selector: matchLabels: app.kubernetes.io/name: {{ include "nextcloud.name" . }} diff --git a/stable/nextcloud/values.yaml b/stable/nextcloud/values.yaml index 0bea8bee1d..065a8b2cf1 100644 --- a/stable/nextcloud/values.yaml +++ b/stable/nextcloud/values.yaml @@ -125,6 +125,16 @@ nextcloud: # ) # ); + ## Strategy used to replace old pods + ## IMPORTANT: use with care, it is suggested to leave as that for upgrade purposes + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy + strategy: + type: Recreate + # type: RollingUpdate + # rollingUpdate: + # maxSurge: 1 + # maxUnavailable: 0 + ## ## Extra environment variables extraEnv: