Back to results for “Applications”
ArgoCD › Sync Waves & Hooks

Can hooks use sync waves to order among themselves?

Intermediate

Answer

Yes—hooks honor the sync-wave annotation within their phase, so multiple PreSync hooks can be ordered (e.g., provision in wave -2, migrate in wave -1). This gives fine control over multi-step preparation or teardown sequences inside a single sync.
metadata:
  annotations:
    argocd.argoproj.io/hook: PreSync
    argocd.argoproj.io/sync-wave: "-1"
Real-world example Provisioning runs in an earlier PreSync wave than the migration that depends on it.

Common follow-ups: Do hooks respect waves? | How do you order two PreSync hooks?