Skip to content

Commit

Permalink
[stable/odoo] bump major version
Browse files Browse the repository at this point in the history
Helm performs a lookup for the object based on its group (apps), version (v1), and kind (Deployment). Also known as its GroupVersionKind, or GVK. Changing the GVK is considered a compatibility breaker from Kubernetes' point of view, so you cannot "upgrade" those objects to the new GVK in-place. Earlier versions of Helm 3 did not perform the lookup correctly which has since been fixed to match the spec.

In helm#17352 the `apiVersion` of the deployment resources was updated to `apps/v1` in tune with the api's deprecated, resulting in compatibility breakage.

This major version signifies this change.

Signed-off-by: Sameer Naik <sameersbn@vmware.com>
  • Loading branch information
Sameer Naik committed Nov 9, 2019
1 parent a5744c1 commit a35c826
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 6 deletions.
2 changes: 1 addition & 1 deletion stable/odoo/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v1
name: odoo
version: 11.1.11
version: 12.0.0
appVersion: 12.0.20191015
description: A suite of web based open source business apps.
home: https://www.odoo.com/
Expand Down
8 changes: 8 additions & 0 deletions stable/odoo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,14 @@ See the [Parameters](#parameters) section to configure the PVC or to disable per

## Upgrading

### To 12.0.0

Helm performs a lookup for the object based on its group (apps), version (v1), and kind (Deployment). Also known as its GroupVersionKind, or GVK. Changing the GVK is considered a compatibility breaker from Kubernetes' point of view, so you cannot "upgrade" those objects to the new GVK in-place. Earlier versions of Helm 3 did not perform the lookup correctly which has since been fixed to match the spec.

In https://github.com/helm/charts/pull/17352 the `apiVersion` of the deployment resources was updated to `apps/v1` in tune with the api's deprecated, resulting in compatibility breakage.

This major version signifies this change.

### To 3.0.0

Backwards compatibility is not guaranteed unless you modify the labels used on the chart's deployments.
Expand Down
6 changes: 3 additions & 3 deletions stable/odoo/requirements.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies:
- name: postgresql
repository: https://kubernetes-charts.storage.googleapis.com/
version: 6.5.4
digest: sha256:3fb60c16194499f6ebb30080e98e402f6c6d0fcf1133b8b03c2a90224b3fc291
generated: 2019-10-29T18:16:22.284254529Z
version: 7.0.0
digest: sha256:e7c3fc1c0606c69cfd4240a86f1ada88086f7b37b51d16a4ce56cf48314065e3
generated: "2019-11-09T11:07:10.545595711+05:30"
2 changes: 1 addition & 1 deletion stable/odoo/requirements.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
dependencies:
- name: postgresql
condition: postgresql.enabled
version: 6.x.x
version: 7.x.x
repository: https://kubernetes-charts.storage.googleapis.com/
11 changes: 11 additions & 0 deletions stable/odoo/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,14 @@ but Helm 2.9 and 2.10 does not support it, so we need to implement this if-else
{{- end -}}
{{- end -}}
{{- end -}}

{{/*
Return the appropriate apiVersion for deployment.
*/}}
{{- define "odoo.deployment.apiVersion" -}}
{{- if semverCompare "<1.14-0" .Capabilities.KubeVersion.GitVersion -}}
{{- print "extensions/v1beta1" -}}
{{- else -}}
{{- print "apps/v1" -}}
{{- end -}}
{{- end -}}
2 changes: 1 addition & 1 deletion stable/odoo/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: apps/v1
apiVersion: {{ template "odoo.deployment.apiVersion" . }}
kind: Deployment
metadata:
name: {{ template "odoo.fullname" . }}
Expand Down

0 comments on commit a35c826

Please sign in to comment.