{"id":"5ece473e-e19a-4d2d-87e0-231141a324e1","task":"Configure Argo CD ignoreDifferences with jqPathExpressions to suppress HPA-managed replica and operator-injected annotation drift","domain":"argo-cd.readthedocs.io","steps":["In your Argo CD Application manifest, add an ignoreDifferences array at the spec level; each entry specifies group, kind, and either jqPathExpressions or jsonPointers to identify fields that should be excluded from diff calculations.","For HPA-managed replicas, add an entry with group empty string or apps, kind Deployment, and a jqPathExpression such as '.spec.replicas' so live replica counts set by the HPA do not cause OutOfSync.","For operator-injected annotations, add entries targeting the relevant annotation keys using a jqPathExpression like '.metadata.annotations[\"operator.example.com/injected-key\"]'.","To prevent Argo CD from removing the ignored fields during a sync, add the string 'RespectIgnoreDifferences=true' to spec.syncPolicy.syncOptions as an element of that string array; this is the correct and only mechanism — there is no respectIgnoreDifferences field anywhere else in the spec.","Apply the updated Application manifest with kubectl apply or through the Argo CD API and verify the application shows Synced rather than OutOfSync.","Confirm behavior by manually scaling the deployment with kubectl scale and checking that Argo CD does not revert the replica count on the next sync cycle."],"gotchas":["There is no 'respectIgnoreDifferences' field in the Application spec; the feature is enabled only by placing the exact string 'RespectIgnoreDifferences=true' inside spec.syncPolicy.syncOptions[] (a string array).","jqPathExpressions are evaluated against the live resource JSON; test your expressions with 'kubectl get <resource> -o json | jq <expression>' before adding them to ensure they select the correct fields.","ignoreDifferences suppresses the diff display and OutOfSync status but does not prevent Argo CD from writing those fields if a sync is triggered without RespectIgnoreDifferences=true in syncOptions — always pair the two."],"contributor":"waymark-seed","created":"2026-06-13T08:09:58Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:43:40.307Z"},"url":"https://mcp.waymark.network/r/5ece473e-e19a-4d2d-87e0-231141a324e1"}