Skip to content

Commit 471ab10

Browse files
dfarrell07tpantelis
authored andcommitted
Add bump-task-refs step to Konflux setup workflow
The workflow was missing the step to update Tekton task references to their latest trusted SHAs, causing EC violations after setup. Signed-off-by: Daniel Farrell <[email protected]>
1 parent f3119e8 commit 471ab10

File tree

1 file changed

+26
-2
lines changed

1 file changed

+26
-2
lines changed

.agents/workflows/konflux-subctl-setup.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,39 @@ git add .tekton/subctl-0-${TARGET_VERSION}-*.yaml package/Dockerfile.subctl.konf
5252
git commit -s -m "Add Konflux config for subctl"
5353
```
5454

55-
##### 5. Review and Push
55+
##### 5. Update Tekton Task References
56+
57+
```bash
58+
bash << 'EOF'
59+
set -e
60+
61+
PATCHER_SHA="b001763bb1cd0286a894cfb570fe12dd7f4504bd"
62+
EXPECTED_SHA256="080ad5d7cf7d0cee732a774b7e4dda0e2ccf26b58e08a8516a3b812bc73beb53"
63+
64+
SCRIPT=$(curl -sL "https://raw.githubusercontent.com/simonbaird/konflux-pipeline-patcher/${PATCHER_SHA}/pipeline-patcher")
65+
ACTUAL_SHA256=$(echo "$SCRIPT" | sha256sum | cut -d' ' -f1)
66+
67+
if [[ "$ACTUAL_SHA256" != "$EXPECTED_SHA256" ]]; then
68+
echo "ERROR: Script checksum mismatch!"
69+
exit 1
70+
fi
71+
72+
echo "$SCRIPT" | bash -s bump-task-refs
73+
EOF
74+
git diff --quiet .tekton/*.yaml || \
75+
{ git add .tekton/*.yaml && \
76+
git commit -s -m "Update Tekton task references to latest versions"; }
77+
```
78+
79+
##### 6. Review and Push
5680

5781
```bash
5882
git log origin/<target-branch>..HEAD
5983
git status
6084
git push origin konflux-subctl-<X-Y> --force-with-lease
6185
```
6286

63-
Expected: 2 commits (bot's initial + your configuration), clean working tree.
87+
Expected: 3 commits (bot's initial + configuration + task refs update), clean working tree.
6488

6589
**Troubleshooting:**
6690

0 commit comments

Comments
 (0)