ci: simplify /build-images to always build PR HEAD - #3076
Conversation
Allow /build-images with no argument (defaults to PR HEAD SHA) and validate that any provided SHA actually belongs to a commit in the PR, preventing builds from arbitrary commits in the fork repo. Assisted-by: Claude <noreply@anthropic.com>
|
/build-images |
|
❌ Image build failed See workflow run for details: https://github.com/redhat-developer/rhdh-operator/actions/runs/28113224441 Triggered by @rm3l |
|
/build-images 10e3338 |
/build-images SHA handling and validation
|
✅ PR images built successfully! Images are available for testing:
Also available with PR number tag:
Triggered by @rm3l |
This is misleading as |
The PR HEAD SHA comes from the GitHub API and is already trusted — no need to iterate over the commit list when no SHA argument is given. Assisted-by: Claude <noreply@anthropic.com>
|
/cc @gazarenkov |
Looking for bugs?Check back in a few minutes. Qodo's review agents are on it. |
PR Summary by QodoHarden /build-images SHA parsing and restrict builds to PR commits Description
Diagram
High-Level Assessment
Files changed (2)
|
|
/cherry-pick release-1.10 |
|
@rm3l: once the present PR merges, I will cherry-pick it on top of DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Removes SHA argument parsing and commit validation — /build-images now always builds the HEAD of the PR branch. The SHA comes directly from the GitHub API (pr.data.head.sha), which is trusted. Assisted-by: Claude <noreply@anthropic.com>
/build-images SHA handling and validation/build-images to always build PR HEAD
/build-images to always build PR HEAD/build-images to always build PR HEAD
|
|
@rm3l: #3076 failed to apply on top of branch "release-1.10": DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
@rm3l: #3076 failed to apply on top of branch "release-1.9": DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |



Description
Follow-up to #2293 (59554ed) — simplifies the
/build-imagesslash command to always build the HEAD of the PR branch./build-imagesno longer accepts or requires a commit SHApr.data.head.shadirectly from the GitHub API, which is trusted and always points to the latest PR commitWhich issue(s) does this PR fix or relate to
/build-imagesto always build PR HEAD #3076 (comment) : commit 10e3338 does not belong to this PR branch, but is on a different branch.PR acceptance criteria
How to test changes / Special notes to the reviewer
Can only be tested after merging:
/build-imageson a PR — should build the PR HEAD