Originally created by: kinseii
An option is needed to enable automatic updating of appVersion when updating CozyStack.
apiVersion: apps.cozystack.io/v1alpha1
appVersion: 0.25.2
kind: Kubernetes
It should be disabled by default so that existing clusters do not start updating without the administrator's consent.
There should also be an option to set a maintenance window.
And another option to specify the version:
Possible values:
autoUpdateAppVersionKubernetes:
enabled: false
channel: latest-1 # It can be: "latest", "latest-1", "latest-2"
schedule:
- day: Monday
hourSlots:
- 22
- day: Wednesday
hourSlots:
- 2
- 3
duration: PT4H
A possible implementation of the maintenance and schedule can be found here:
https://learn.microsoft.com/en-us/azure/aks/auto-upgrade-cluster
https://learn.microsoft.com/en-us/azure/aks/planned-maintenance
The same logic is necessary for the Kubernetes version:
For that value: https://github.com/cozystack/cozystack/blob/19b79b7ca435ef4ac73220bedf15cba6911ba824/hack/e2e-apps/kubernetes.bats#L68
Possible values:
autoUpdateVersionKubernetes:
enabled: false
channel: latest-1 # It can be: "latest", "latest-1", "latest-2"
schedule:
- day: Monday
hourSlots:
- 22
- day: Wednesday
hourSlots:
- 2
- 3
duration: PT4H