Skip to content

Commit

Permalink
set docker image tag from git tag
Browse files Browse the repository at this point in the history
Signed-off-by: xeptore <[email protected]>
  • Loading branch information
xeptore committed Mar 22, 2023
1 parent da05a30 commit f7ecde6
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
branches:
- main
tags:
- "v*.*.*"
- "v[0-9]+.[0-9]+.[0-9]+"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
Expand Down Expand Up @@ -50,12 +50,17 @@ jobs:
images: |
ghcr.io/${{ github.repository }}/ingest
tags: |
type=edge
type=edge,enable=${{ github.event_name == 'push' && github.ref_protected && github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch && github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
type=semver,pattern={{version}}
type=semver,pattern={{major}}
type=semver,pattern={{major}}.{{minor}}
labels: |
maintainer=${{ github.repository_owner }}
org.opencontainers.image.authors=${{ github.repository_owner }}
flavor: |
latest=true
latest=${{ github.ref_type != 'tag' && !startsWith(github.ref, 'refs/tags/') }}
prefix=,onlatest=false
suffix=,onlatest=false
- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v2
with:
Expand Down

0 comments on commit f7ecde6

Please sign in to comment.