fix: release action

This commit is contained in:
Steven 2024-07-27 21:21:09 -04:00
parent 4870433289
commit a948555166

View File

@ -57,16 +57,12 @@ jobs:
tags: |
type=semver,pattern={{version}},value=${{ env.VERSION }}
type=semver,pattern={{major}}.{{minor}},value=${{ env.VERSION }}
${{ startsWith(github.ref, 'refs/tags/') && 'type=raw,value=stable' }}
flavor: |
latest=true
labels: |
org.opencontainers.image.version=${{ env.VERSION }}
# Add stable tag if it's from a tag release.
- name: Add stable tag
if: startsWith(github.ref, 'refs/tags/')
run: echo "STABLE_TAG=stable" >> $GITHUB_ENV
- name: Build and Push
id: docker_build
uses: docker/build-push-action@v6
@ -75,5 +71,5 @@ jobs:
file: ./Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}${{ env.STABLE_TAG && ','+env.STABLE_TAG }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}