diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 642a461..aec0462 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -1,7 +1,6 @@ -on: +on: push: - branches: - - "*" + pull_request: name: CI build jobs: @@ -45,6 +44,10 @@ jobs: type=ref,event=branch type=ref,event=tag type=ref,event=pr + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}},enable=${{ !startsWith(github.ref, 'refs/tags/v0.') }} + type=raw,value=latest,enable={{is_default_branch}} type=raw,value={{branch}}-{{sha}}-{{date 'X'}},enable=${{ github.event_name != 'pull_request' }} - name: Build and push uses: docker/build-push-action@v5 @@ -65,6 +68,10 @@ jobs: type=ref,event=branch type=ref,event=tag type=ref,event=pr + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}},enable=${{ !startsWith(github.ref, 'refs/tags/v0.') }} + type=raw,value=latest,enable={{is_default_branch}} type=raw,value={{branch}}-{{sha}}-{{date 'X'}},enable=${{ github.event_name != 'pull_request' }} - name: Build and push uses: docker/build-push-action@v5