-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
It's up to consideration.
I think it makes sense to prefer kubectl.kubernetes.io/last-applied-configuration annotation over qbec.io/last-applied and always remove the first one because of the few reasons:
- If both annotations exists, then most probably resource was applied using qbec and using kubectl afterwards.
This means we need to consider the latest configuration applied via kubectl, and ignore qbec annotation. - Better integration with ArgoCD, since it uses kubectl for applying resources, we don't need
--show-pristineoption anymore.
Another problem of--show-pristineis the fact that it adds additional difficulties for hiding this information (see Option to hide sensitive data in specific fields argoproj/argo-cd#5201) I think this solution is better and more clear than proposed on Add option to dispay qbec.io/component and qbec.io/last-applied in show #163 and PR Use namespaced queries when multiple namespaces present, allow override using spec property #167.
Current behavior:
qbec.io/last-applied |
kubectl.kubernetes.io/last-applied-configuration |
Behavior |
|---|---|---|
| missing | missing | use resource body, write qbec.io/last-applied |
| exists | missing | use qbec.io/last-applied, write qbec.io/last-applied |
| missing | exists | use kubectl.kubernetes.io/last-applied-configuration, delete kubectl.kubernetes.io/last-applied-configuration, write qbec.io/last-applied |
| exists | exists | use qbec.io/last-applied, write qbec.io/last-applied |
My idea is to change the last case behavior to:
qbec.io/last-applied |
kubectl.kubernetes.io/last-applied-configuration |
Behavior |
|---|---|---|
| exists | exists | use kubectl.kubernetes.io/last-applied-configuration, delete kubectl.kubernetes.io/last-applied-configuration, write qbec.io/last-applied |
Metadata
Metadata
Assignees
Labels
No labels