Skip to content

Commit

Permalink
[stable/mongodb] Fix chart not being upgradable when replicaset is en…
Browse files Browse the repository at this point in the history
…abled. (helm#10121)

Signed-off-by: juan131 <juan@bitnami.com>
  • Loading branch information
juan131 authored and coreypobrien committed Dec 31, 2018
1 parent ef2d9eb commit b129d95
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion stable/mongodb/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: mongodb
version: 4.10.1
version: 5.0.0
appVersion: 4.0.3
description: NoSQL document-oriented database that stores JSON-like documents with dynamic schemas, simplifying the integration of data in content-driven applications.
keywords:
Expand Down
11 changes: 11 additions & 0 deletions stable/mongodb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,3 +174,14 @@ The allowed extensions are `.sh`, and `.js`.
The [Bitnami MongoDB](https://github.com/bitnami/bitnami-docker-mongodb) image stores the MongoDB data and configurations at the `/bitnami/mongodb` path of the container.

The chart mounts a [Persistent Volume](http://kubernetes.io/docs/user-guide/persistent-volumes/) at this location. The volume is created using dynamic volume provisioning.

## Upgrading

### To 5.0.0

When enabling replicaset configuration, backwards compatibility is not guaranteed unless you modify the labels used on the chart's statefulsets.
Use the workaround below to upgrade from versions previous to 5.0.0. The following example assumes that the release name is `my-release`:

```consoloe
$ kubectl delete statefulset my-release-mongodb-arbiter my-release-mongodb-primary my-release-mongodb-secondary --cascade=false
```
1 change: 0 additions & 1 deletion stable/mongodb/templates/statefulset-arbiter-rs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ spec:
matchLabels:
app: {{ template "mongodb.name" . }}
release: {{ .Release.Name }}
chart: {{ template "mongodb.chart" . }}
component: arbiter
serviceName: {{ template "mongodb.fullname" . }}-headless
replicas: {{ .Values.replicaSet.replicas.arbiter }}
Expand Down
1 change: 0 additions & 1 deletion stable/mongodb/templates/statefulset-primary-rs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ spec:
selector:
matchLabels:
app: {{ template "mongodb.name" . }}
chart: {{ template "mongodb.chart" . }}
release: {{ .Release.Name }}
component: primary
template:
Expand Down
1 change: 0 additions & 1 deletion stable/mongodb/templates/statefulset-secondary-rs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ spec:
matchLabels:
app: {{ template "mongodb.name" . }}
release: {{ .Release.Name }}
chart: {{ template "mongodb.chart" . }}
component: secondary
podManagementPolicy: "Parallel"
serviceName: {{ template "mongodb.fullname" . }}-headless
Expand Down

0 comments on commit b129d95

Please sign in to comment.