You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To reduce the risk of forgetting or missing to run the apply migration step we should add some state to the cluster such that it knows what was last applied.
Then when you run the prepare command it could check and make sure that both the config and the cluster state has a valid version.
Proposed alternatives
Since we would like to be able to catch if any of the migration scrips were missed we should probably have this apply be done in the migration apply step and not directly in apps.
Additional context
Some thing to consider:
How to implement? ConfigMap, labels, etc.
How to handle when you are not on a tag?
Should this only be checked when preparing an upgrade or also e.g. when running bin/ck8s apply?
Definition of done
The current applied apps version is stored in the environment
Some prepare step should validate that the cluster is using a valid version before continuing
The text was updated successfully, but these errors were encountered:
Nope, because that's changed when doing the prepare step. So until the apply step is ran there is a discrepancy between the "config version" and the "runtime version".
And if the cluster is upgraded using tekton, for example, and that pipelinerun fails this will be an issue until the apply step is ran again, or manually.
So this issue tries to catch that discrepancy the next time the prepare step is run. Such that you don't upgrade another minor version which we don't support
Ah, I understand the problem better now! I wish we didn't have to use the config to keep "runtime information/state" though. Ideally you would be able to query Kubernetes to know what is currently installed and diff that with what is currently in the config but I guess we don't store the ck8sVersion anywhere in Kubernetes. 😄
Exactly! so basically that's what I would like us to do. Add a CM into kube-system or something that has the current applied version. That's what I meant with "add some state to the cluster"
Ajarmar
changed the title
Add applied apps version to cluster state
[3] Add applied apps version to cluster state
Nov 29, 2024
Proposed feature
To reduce the risk of forgetting or missing to run the apply migration step we should add some state to the cluster such that it knows what was last applied.
Then when you run the prepare command it could check and make sure that both the config and the cluster state has a valid version.
Proposed alternatives
Since we would like to be able to catch if any of the migration scrips were missed we should probably have this apply be done in the migration apply step and not directly in apps.
Additional context
Some thing to consider:
bin/ck8s apply
?Definition of done
The text was updated successfully, but these errors were encountered: