Menu

#1310 [Feature] Automatic update appVersion of `kind: Kubernetes` and version Kubernetes itself

open
nobody
None
2025-08-05
2025-08-05
Anonymous
No

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:

  • latest (for example: 0.25)
  • latest-1 (-1 from minor version, for example: 0.24)
  • latest-2 (-2 from minor version, for example: 0.23)

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:

  • latest (for example: 1.33)
  • latest-1 (-1 from minor version, for example: 1.32)
  • latest-2 (-2 from minor version, for example: 1.31)

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

Discussion


Log in to post a comment.

MongoDB Logo MongoDB