Skip to content

Commit fa4f306

Browse files
author
Adrián Parilli
committed
Added tags for semver (major, minor & patch)
1 parent 64a908e commit fa4f306

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/workflows/docker-publish.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ on:
99
#schedule:
1010
#- cron: '23 3 * * *'
1111
push:
12-
branches: [ "unraid" ]
12+
branches: [ "master" ]
1313
# Publish semver tags as releases.
1414
tags: [ 'v*.*.*' ]
1515
pull_request:
16-
branches: [ "unraid" ]
16+
branches: [ "master" ]
1717

1818
env:
1919
# Use docker.io for Docker Hub if empty
@@ -68,8 +68,12 @@ jobs:
6868
with:
6969
images: ${{ env.REGISTRY }}/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}
7070
tags: |
71-
# set latest tag for unraid branch
72-
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'unraid') }}
71+
# set latest tag for default branch
72+
type=raw,value=latest,enable={{is_default_branch}}
73+
# set version tag from semver
74+
type=semver,pattern={{major}}
75+
type=semver,pattern={{major}}.{{minor}}
76+
type=semver,pattern={{major}}.{{minor}}.{{patch}}
7377
7478
# Build and push Docker image with Buildx (don't push on PR)
7579
# https://github.com/docker/build-push-action

0 commit comments

Comments
 (0)