Skip to content

Commit e67f654

Browse files
committed
updated action
1 parent 2c9a660 commit e67f654

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

.github/workflows/docker-image.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ jobs:
3939
images: ${{ env.REGISTRY_IMAGE }}
4040
tags: |
4141
type=ref,event=tag
42-
type=semver,pattern={{version}},enable={{is_semver}}
43-
type=semver,pattern={{major}}.{{minor}},enable={{is_semver}}
44-
type=semver,pattern={{major}},enable={{is_semver}}
45-
type=ref,event=branch,enable={{is_default_branch}}
42+
type=semver,pattern={{version}},enable=${{ startsWith(github.ref, 'refs/tags/v') }}
43+
type=semver,pattern={{major}}.{{minor}},enable=${{ startsWith(github.ref, 'refs/tags/v') }}
44+
type=semver,pattern={{major}},enable=${{ startsWith(github.ref, 'refs/tags/v') }}
45+
type=ref,event=branch
4646
type=sha
47-
type=raw,value=latest,enable={{is_default_branch}}
48-
type=raw,value=latest,enable={{is_tag}}
47+
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/main' }}
48+
type=raw,value=latest,enable=${{ startsWith(github.ref, 'refs/tags/v') }}
4949
5050
- name: Build and push
5151
uses: docker/build-push-action@v6

0 commit comments

Comments
 (0)