Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bitnami/nginx-ingress-controller] Fix chart not being upgradable #808

Merged
merged 1 commit into from
Sep 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion bitnami/nginx-ingress-controller/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: nginx-ingress-controller
version: 0.0.1
version: 1.0.0
appVersion: 0.18.0
description: Chart for the nginx Ingress controller
keywords:
Expand Down
15 changes: 15 additions & 0 deletions bitnami/nginx-ingress-controller/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,3 +177,18 @@ $ helm install --name my-release -f values.yaml bitnami/nginx-ingress-controller
```

> **Tip**: You can use the default [values.yaml](values.yaml)

## Upgrading

### To 1.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 1.0.0. The following example assumes that the release name is nginx-ingress-controller:

```console
$ kubectl patch deployment nginx-ingress-controller-default-backend --type=json -p='[{"op": "remove", "path": "/spec/selector/matchLabels/chart"}]'
# If using deployments
$ kubectl patch deployment nginx-ingress-controller --type=json -p='[{"op": "remove", "path": "/spec/selector/matchLabels/chart"}]'
# If using daemonsets
$ kubectl patch daemonset nginx-ingress-controller --type=json -p='[{"op": "remove", "path": "/spec/selector/matchLabels/chart"}]'
```
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ metadata:
release: {{ .Release.Name }}
name: {{ template "nginx-ingress.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "nginx-ingress.name" . }}
release: "{{ .Release.Name }}"
component: "{{ .Values.name }}"
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
updateStrategy:
{{ toYaml .Values.updateStrategy | indent 4 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ metadata:
release: {{ .Release.Name }}
name: {{ template "nginx-ingress.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "nginx-ingress.name" . }}
release: "{{ .Release.Name }}"
component: "{{ .Values.name }}"
replicas: {{ .Values.replicaCount }}
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
strategy:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ metadata:
release: {{ .Release.Name }}
name: {{ template "nginx-ingress.defaultBackend.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "nginx-ingress.name" . }}
release: "{{ .Release.Name }}"
replicas: {{ .Values.defaultBackend.replicaCount }}
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
template:
Expand Down