From bbf424a10e5f9cbcd41edfa50579c376f3f38b95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20J=2E=20Salmer=C3=B3n-Garc=C3=ADa?= Date: Thu, 20 Sep 2018 16:47:27 +0200 Subject: [PATCH] [stable/testlink] Fix chart not being upgradable (#7853) Signed-off-by: Javier J. Salmeron Garcia --- stable/testlink/Chart.yaml | 2 +- stable/testlink/README.md | 12 ++++++++++++ stable/testlink/templates/deployment.yaml | 4 ++++ 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/stable/testlink/Chart.yaml b/stable/testlink/Chart.yaml index c0b4cef230..66d673f9f7 100644 --- a/stable/testlink/Chart.yaml +++ b/stable/testlink/Chart.yaml @@ -1,5 +1,5 @@ name: testlink -version: 2.1.0 +version: 3.0.0 appVersion: 1.9.17 description: Web-based test management system that facilitates software quality assurance. icon: https://bitnami.com/assets/stacks/testlink/img/testlink-stack-220x234.png diff --git a/stable/testlink/README.md b/stable/testlink/README.md index c4a857977d..d299cced1f 100644 --- a/stable/testlink/README.md +++ b/stable/testlink/README.md @@ -108,3 +108,15 @@ The [Bitnami TestLink](https://github.com/bitnami/bitnami-docker-testlink) image Persistent Volume Claims are used to keep the data across deployments. This is known to work in GCE, AWS, and minikube. See the [Configuration](#configuration) section to configure the PVC or to disable persistence. + +## Upgrading + +### To 3.0.0 + +Backwards compatibility is not guaranteed unless you modify the labels used on the chart's deployments. +Use the workaround below to upgrade from versions previous to 3.0.0. The following example assumes that the release name is testlink: + +```console +$ kubectl patch deployment testlink-testlink --type=json -p='[{"op": "remove", "path": "/spec/selector/matchLabels/chart"}]' +$ kubectl delete statefulset testlink-mariadb --cascade=false +``` diff --git a/stable/testlink/templates/deployment.yaml b/stable/testlink/templates/deployment.yaml index 26c15a6997..d8646ec6d6 100644 --- a/stable/testlink/templates/deployment.yaml +++ b/stable/testlink/templates/deployment.yaml @@ -8,6 +8,10 @@ metadata: release: "{{ .Release.Name }}" heritage: "{{ .Release.Service }}" spec: + selector: + matchLabels: + app: {{ template "fullname" . }} + release: "{{ .Release.Name }}" replicas: 1 template: metadata: