Skip to content

Commit bc0fca7

Browse files
ianpittwoodclaude
andcommitted
Collapse bakery-build-native merge matrix into a single ordered job
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 9232b17 commit bc0fca7

1 file changed

Lines changed: 3 additions & 25 deletions

File tree

.github/workflows/bakery-build-native.yml

Lines changed: 3 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,6 @@ jobs:
9999
contents: read
100100
outputs:
101101
platform-matrix: ${{ steps.images-by-platform.outputs.platform_matrix }}
102-
versions-matrix: ${{ steps.images-by-version.outputs.versions_matrix }}
103102

104103
steps:
105104
- name: Checkout
@@ -125,21 +124,6 @@ jobs:
125124
[[ -n "$DEV_STREAM" ]] && ARGS+=(--dev-stream "$DEV_STREAM")
126125
result=$(bakery ci matrix "${ARGS[@]}")
127126
echo "platform_matrix=$(echo "$result" | jq --compact-output .)" >> "$GITHUB_OUTPUT"
128-
- name: Images by Version
129-
id: images-by-version
130-
env:
131-
DEV_VERSIONS: ${{ inputs.dev-versions }}
132-
MATRIX_VERSIONS: ${{ inputs.matrix-versions }}
133-
IMAGE_VERSION: ${{ inputs.image-version }}
134-
DEV_STREAM: ${{ inputs.dev-stream }}
135-
CONTEXT: ${{ inputs.context }}
136-
run: |
137-
IMAGE_VERSION="${IMAGE_VERSION#v}"
138-
ARGS=(--quiet --dev-versions "$DEV_VERSIONS" --matrix-versions "$MATRIX_VERSIONS" --exclude platform --context "$CONTEXT")
139-
[[ -n "$IMAGE_VERSION" ]] && ARGS+=(--image-version "$IMAGE_VERSION")
140-
[[ -n "$DEV_STREAM" ]] && ARGS+=(--dev-stream "$DEV_STREAM")
141-
result=$(bakery ci matrix "${ARGS[@]}")
142-
echo "versions_matrix=$(echo "$result" | jq --compact-output .)" >> "$GITHUB_OUTPUT"
143127
144128
build-test:
145129
name: "Build/Test ${{ matrix.img.image }}:${{ matrix.img.version }} (${{ matrix.img.platform }})"
@@ -279,17 +263,11 @@ jobs:
279263
overwrite: 'true'
280264

281265
merge:
282-
name: "Merge/Push ${{ matrix.img.image }}:${{ matrix.img.version }}"
266+
name: "Merge/Push"
283267
permissions:
284268
contents: read
285269
packages: write
286-
needs:
287-
- matrix
288-
- build-test
289-
strategy:
290-
fail-fast: false
291-
matrix:
292-
img: ${{ fromJson(needs.matrix.outputs.versions-matrix) }}
270+
needs: [build-test]
293271
runs-on: ${{ inputs.merge-builder }}
294272

295273
steps:
@@ -357,7 +335,7 @@ jobs:
357335
- name: Download Metadata
358336
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
359337
with:
360-
pattern: "${{ matrix.img.image }}-${{ matrix.img.version }}-*-metadata"
338+
pattern: "*-metadata"
361339
merge-multiple: true
362340

363341
- name: List files

0 commit comments

Comments
 (0)