Skip to content

Commit f8b903f

Browse files
committed
using metadata
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
1 parent 13c4602 commit f8b903f

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

.github/workflows/ci.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ jobs:
9797
TELEMETRY_HEADER: ${{ secrets.TELEMETRY_HEADER }}
9898

9999
build-image:
100-
# remove once this works on main
101-
# if: startsWith(github.ref, 'refs/tags/v')
100+
if: startsWith(github.ref, 'refs/tags/v')
102101
needs: [build]
103102
runs-on: ubuntu-latest
104103
steps:
@@ -118,13 +117,19 @@ jobs:
118117
- name: Set up Docker Buildx
119118
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
120119

120+
- name: Docker metadata
121+
id: meta
122+
uses: docker/metadata-action@v5
123+
with:
124+
images: docker/cagent
125+
121126
- name: Build and push image
122127
uses: docker/build-push-action@v5
123128
with:
124129
context: .
125130
push: ${{ github.event_name != 'pull_request' }}
126131
sbom: true
127132
provenance: mode=max
128-
tags: ${{ steps.metadata.outputs.tags }}
129-
labels: ${{ steps.metadata.outputs.labels }}
133+
tags: ${{ steps.meta.outputs.tags }}
134+
labels: ${{ steps.meta.outputs.labels }}
130135
build-args: GIT_COMMIT=${{ github.sha }}

0 commit comments

Comments
 (0)