feat(ci): dispatch a repository event when the main webapp image is published#3875
Conversation
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (1)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
🔇 Additional comments (2)
WalkthroughThis PR adds GitHub Actions infrastructure to export container image digests and trigger downstream jobs in a cloud repository. The publish-webapp workflow now outputs the multi-arch image digest from its build step, making it available to dependent workflows. A new dispatch-main-image job consumes this digest and sends a repository_dispatch event to triggerdotdev/cloud when main-branch versions are published in the canonical repository, passing the digest-pinned image reference and commit SHA as event payload data. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…ublished After the webapp image is pushed on a main build, emit a repository_dispatch (main-image-published) carrying a digest-pinned image ref so other repositories in the org can build or deploy from the exact artifact rather than chasing the moving main tag. Fires only for the mutable main tag, never semver releases or other tag builds, and only from the canonical repo.
32b54a4 to
819da36
Compare
Summary
On every
mainbuild, once the webapp image is pushed to the registry, the publish workflow emits a cross-reporepository_dispatchevent (main-image-published) carrying a digest-pinned image ref. Other repositories in the org can subscribe to that event and build or deploy from the exact artifact, instead of chasing the movingmaintag.Design
publish-webapp.ymlnow exposes the pushed multi-arch index digest as a workflow output.publish.ymladds adispatch-main-imagejob (afterpublish-webapp) that builds<image_repo>@<digest>and sends the dispatch via the same pinnedpeter-evans/repository-dispatchaction already used elsewhere in this repo, authed withCROSS_REPO_PAT.It fires only when the published tag is
main, so semver releases and other tag builds are excluded, and only from the canonical repo so forks never dispatch. The payload is JSON-escaped withjq.