Open bh-tt opened 9 months ago
Note that setting .spec.syncPolicy: {}
still resolves to an application that does not have the key at all (due to defaults?). The same goes for setting .spec.syncPolicy.syncOptions
to a value or setting .spec.syncPolicy.automated: null
, the last one does not detect any differences despite the key having different values for desired and live manifests.
I'm facing the same problem. Using v2.10.5+ When I set
syncPolicy: null
argocd does not detect manual changes to the application manifest. However when I change the manifest in git from
syncPolicy: automated: {}
To:
syncPolicy: null
Changes are detected.
Checklist:
argocd version
.Describe the bug When deploying an app-of-apps pattern, I'd like to enforce the automatic sync policy on the child apps, even when that sync policy is 'no automatic sync'. Right now the only way to describe no sync is to leave out the
.spec.syncPolicy
setting, which resolves to an app without.spec.syncPolicy
due to defaults, which means the sync policy can be manually changed to something else and ArgoCD will still consider the child app to be Synced.Note: this is likely caused by #16092.
To Reproduce
.spec.syncPolicy
set to{}
(or that does not have it at all).spec.syncPolicy
field compared to Git.Example apps:
Expected behavior I expect to be able to set a sync policy for a child app and that argocd will show the app as OutOfSync when the child app syncPolicy deviates from the git-defined syncPolicy.
Screenshots
Version
Logs
Potential fixes If it is not possible to fix #16092 (with a sync option enforcing that the live manifest matches the desired manifest exactly or something), I think an added field like
.spec.syncPolicy.automated.enabled
may be needed, to allow disabling automatic sync without leaving.spec.syncPolicy
as a whole empty.