From 0808f1ac0eee2d21b222ef661fc0330c1a2f6fd5 Mon Sep 17 00:00:00 2001 From: Mitchell Scott <10804314+rmitchellscott@users.noreply.github.com> Date: Thu, 4 Jan 2024 13:17:51 -0700 Subject: [PATCH] Update checkout action to v4, add semver git tags to Docker image tags --- .github/workflows/build-docker.yaml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-docker.yaml b/.github/workflows/build-docker.yaml index 17cf049..f49a1ee 100644 --- a/.github/workflows/build-docker.yaml +++ b/.github/workflows/build-docker.yaml @@ -10,19 +10,22 @@ jobs: packages: write steps: - name: Checkout - uses: actions/checkout@v3 - - id: short-sha - uses: benjlevesque/short-sha@v1.2 + uses: actions/checkout@v4 - name: Docker meta id: meta uses: docker/metadata-action@v4 with: images: | ghcr.io/netbymatt/ws4kp + flavor: | + latest=false tags: | type=raw,priority=1000,value=latest,enable=${{ github.ref == 'refs/heads/main' }} type=ref,event=branch - ${{ steps.short-sha.outputs.sha }} + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} + type=sha - name: Set up QEMU uses: docker/setup-qemu-action@v2 - name: Set up Buildx @@ -44,4 +47,4 @@ jobs: tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} cache-from: type=gha - cache-to: type=gha,mode=max \ No newline at end of file + cache-to: type=gha,mode=max