Repository navigation
Fix concurrent GitOps image publication on main - #13
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 57bc0ad8cf
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| - name: Test GitOps publication against disposable Git repositories | ||
| run: bash scripts/test-gitops-publication.sh |
There was a problem hiding this comment.
Document the new publication policy and local integration test
This change introduces a new GitOps publication policy and a disposable integration test, but does not update any README or documentation. Document that superseded source commits now skip deployment successfully, and include bash scripts/test-gitops-publication.sh as the local verification command so maintainers can interpret skipped publications and reproduce the CI check. The repository's AGENTS.md explicitly requires relevant documentation updates in the same change when commands, tests, or boundaries change.
AGENTS.md reference: AGENTS.md:L110-L110
Useful? React with 👍 / 👎.
The failed main GitOps job built, scanned and published its immutable image, but tried to rebase a generated deployment commit across a concurrent update to the same image field.
Require the scanned source SHA to still be main's current remote tip, and publish only with a regular fast-forward push. If main moves in flight, the stale candidate is superseded; if main is unchanged and a push fails, retain a failed job. Only the single Governor image field is edited. The existing build, scan, Docker Hub, and PR/main gates are unchanged.
Disposable bare-Git integration covers publication, no-op repeats, stale source, a true ref-update race injected after the initial remote check, and a non-race push rejection. It passed locally and now runs in PR CI. It does not use Docker Hub, production infrastructure or deploy anything; the existing real publication job remains main-only.