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
According to the README --reload-strategy=annotations is intended to work with auto-reconciliation using CD tools loke ArgoCD or FluxCD.
Either I get this wrong, or the README is the wrong way around regarding this point.
From the README regarding --reload-strategy=annotations:
This strategy is useful when using resource syncing tools like ArgoCD, since it will not cause these tools to detect configuration drift after a resource is reloaded.
But to me this seems not to be the case.
CD tools watch the ressources they have manifests for usually deployments or statefulSets, but not pods and containers.
So, for the two strategies, when the CD tool runs a reconciliation the following happens.
--reload-strategy=env-vars
Because only the pod was altered by reloader adding environment variables to it, the CD tool does not see a diff and does not do anything.
--reload-strategy=annotations
Because the deployment or statefulSet was altered by reloader adding a annotation to its PodTemplate the CD tool sees a diff, removes the annotation and thus triggers a rollout.
So as I see it when using CD tools with auto-reconciliation --reload-strategy=env-vars is the way to go.
The text was updated successfully, but these errors were encountered:
Hi, we have a similar issue with our reloader and ArgoCD.
For both strategies, env-vars and annotation, when we change the Kubernetes secret, ArgoCD creates a new replica set and only one pod is reloaded to use a new version of the secret. It is worth mentioning that we use SOPS for secrets.
After a few tests, we figure out that the problem is with the ArgoCD app configuration. We set replace=true for the sync policy in the argoCD app manifest and when we change it to false, both strategies seem to work properly.
Agree that the documentation is a lite bit confusing. How should it be set up correctly? Is it recommended to use the ignoredifferences setting for the annotation strategy?
According to the README
--reload-strategy=annotations
is intended to work with auto-reconciliation using CD tools loke ArgoCD or FluxCD.Either I get this wrong, or the README is the wrong way around regarding this point.
From the README regarding
--reload-strategy=annotations
:But to me this seems not to be the case.
CD tools watch the ressources they have manifests for usually
deployments
orstatefulSets
, but notpods
andcontainers
.So, for the two strategies, when the CD tool runs a reconciliation the following happens.
--reload-strategy=env-vars
Because only the
pod
was altered by reloader adding environment variables to it, the CD tool does not see a diff and does not do anything.--reload-strategy=annotations
Because the
deployment
orstatefulSet
was altered by reloader adding a annotation to itsPodTemplate
the CD tool sees a diff, removes the annotation and thus triggers a rollout.So as I see it when using CD tools with auto-reconciliation
--reload-strategy=env-vars
is the way to go.The text was updated successfully, but these errors were encountered: