Skip to content

Commit 16b12c1

Browse files
simplify tags (#126)
I manually squashed merged this because GitHub seemed to hang while processing my latest commit to this branch (even though the action spawned and completed successfully). commit 0807182 Author: tomeichlersmith <[email protected]> Date: Fri May 23 13:04:30 2025 -0500 share outputs rather than re-run docker-metadata-action commit 78977aa Author: Tom Eichlersmith <[email protected]> Date: Fri May 23 12:37:09 2025 -0500 fix tabbing commit be8edaa Author: Tom Eichlersmith <[email protected]> Date: Tue May 20 16:54:16 2025 -0500 simplify tags only do `pr-NNN`, `branch-name`, `vX.Y.Z`, `latest`, and `sha-XXXXXXXX` types
1 parent ffc7161 commit 16b12c1

File tree

1 file changed

+5
-20
lines changed

1 file changed

+5
-20
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,8 @@ jobs:
4444
tags: |
4545
type=ref,event=branch
4646
type=ref,event=pr
47-
type=semver,pattern={{version}}
48-
type=semver,pattern={{major}}.{{minor}}
4947
type=semver,pattern=v{{version}}
50-
type=semver,pattern=v{{major}}.{{minor}}
48+
type=sha,format=short
5149
-
5250
name: Set up QEMU
5351
uses: docker/setup-qemu-action@v3
@@ -94,6 +92,8 @@ jobs:
9492
runs-on: ubuntu-latest
9593
needs:
9694
- build
95+
outputs:
96+
imagejson: ${{ steps.meta.outputs.json }}
9797
steps:
9898
-
9999
name: Download digests
@@ -114,10 +114,8 @@ jobs:
114114
tags: |
115115
type=ref,event=branch
116116
type=ref,event=pr
117-
type=semver,pattern={{version}}
118-
type=semver,pattern={{major}}.{{minor}}
119117
type=semver,pattern=v{{version}}
120-
type=semver,pattern=v{{major}}.{{minor}}
118+
type=sha,format=short
121119
-
122120
name: Login to Docker Hub
123121
uses: docker/login-action@v3
@@ -160,24 +158,11 @@ jobs:
160158
-
161159
name: Download Build Context for Test Script
162160
uses: actions/checkout@v4
163-
-
164-
name: Docker meta
165-
id: meta
166-
uses: docker/metadata-action@v5
167-
with:
168-
images: ${{ env.REGISTRY_IMAGE }}
169-
tags: |
170-
type=ref,event=branch
171-
type=ref,event=pr
172-
type=semver,pattern={{version}}
173-
type=semver,pattern={{major}}.{{minor}}
174-
type=semver,pattern=v{{version}}
175-
type=semver,pattern=v{{major}}.{{minor}}
176161
-
177162
name: Install just
178163
uses: extractions/setup-just@v3
179164
with:
180165
just-version: 1.26.0
181166
-
182167
name: Test the Image
183-
run: ./ci/test-ldmx-sw $(jq -r .tags[0] <<< "${DOCKER_METADATA_OUTPUT_JSON}") ${{ matrix.ldmx_sw }}
168+
run: ./ci/test-ldmx-sw $(echo '${{ needs.merge.outputs.imagejson }}' | jq -r .tags[0]) ${{ matrix.ldmx_sw }}

0 commit comments

Comments
 (0)