Skip to content

Commit 56092b8

Browse files
committed
Add docker build workflow
1 parent 87a363c commit 56092b8

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

.github/workflows/build.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,15 @@ jobs:
102102
type=semver,pattern={{version}}
103103
type=semver,pattern={{major}}
104104
105+
- name: Docker tags
106+
run: |
107+
if [ -z "$DOCKER_METADATA_OUTPUT_VERSION" ]; then
108+
echo DOCKER_METADATA_OUTPUT_VERSION=${{ github.ref_name }} >> $GITHUB_ENV
109+
fi
110+
if [ -z "$DOCKER_METADATA_OUTPUT_JSON" ]; then
111+
echo DOCKER_METADATA_OUTPUT_JSON='{"tags":["${{ github.ref_name }}"]}' >> $GITHUB_ENV
112+
fi
113+
105114
- name: Create manifest list and push
106115
working-directory: ${{ runner.temp }}/digests
107116
run: |
@@ -110,4 +119,4 @@ jobs:
110119
111120
- name: Inspect image
112121
run: |
113-
docker buildx imagetools inspect ${{ env.GITHUB_CR_REPO }}:${{ steps.meta.outputs.version }}
122+
docker buildx imagetools inspect ${{ env.GITHUB_CR_REPO }}:${{ env.DOCKER_METADATA_OUTPUT_VERSION }}

0 commit comments

Comments
 (0)