Certified GitOps Associate (CGOA) free question 4 / 10 · Domain 2: GitOps Principles
An Argo CD application is pinned to a commit SHA, and a new version of the manifests is pushed to the repository. How does the live state of the pinned application change, according to the tracking strategies page?
- By pushing a commit to the branch, as the pin follows the branch that contains the commit
- By retagging the commit, as Argo CD resolves a pinned SHA through the tag that points at it
- By updating the tracking revision in the application to a different commit that holds the new manifests
- By waiting for the pinned commit to be updated in place with the new manifests
Show the answer and explanation
Answer: C
Why this is correct
The Commit Pinning section says that if a Git commit SHA is specified, the app is effectively pinned to the manifests defined at that commit. This is the most restrictive of the techniques and is typically used to control production environments. Since commit SHAs cannot change meaning, the only way to change the live state of a pinned app is to update the tracking revision to a different commit containing the new manifests.
Why the other options are wrong
"By waiting for the pinned commit to be updated in place with the new manifests" … The page says commit SHAs cannot change meaning, so the pinned commit never receives the new manifests.
"By pushing a commit to the branch, as the pin follows the branch that contains the commit" … A pin to a commit does not follow a branch. A new commit on a branch does not move it.
"By retagging the commit, as Argo CD resolves a pinned SHA through the tag that points at it" … Retagging applies to tag tracking, where the meaning of a tag can change. A pinned SHA is not resolved through a tag.
Key points
Since commit SHAs cannot change meaning, the only way to change the live state of an app that is pinned to a commit is to update the tracking revision to a different commit.