How do sync waves and hooks control ordering in Argo CD?
⚡
Quick Answer
Annotations order resources into waves and run Job hooks at PreSync/Sync/PostSync phases.
Detailed Answer
argocd.argoproj.io/sync-wave orders resources (lower waves first), so a database migration or CRD can apply before the workload that needs it. Sync hooks (PreSync/PostSync) run Jobs at defined phases — e.g. a PreSync migration or a PostSync smoke test — enabling safe, ordered rollouts.
💡
Interview Tip
Give a concrete case: run a DB migration before the Deployment.
argocdsync-waveshooks