diff --git a/.gitea/workflows/build.yaml b/.gitea/workflows/build.yaml index 5e4bea7..9f13eab 100644 --- a/.gitea/workflows/build.yaml +++ b/.gitea/workflows/build.yaml @@ -1,4 +1,7 @@ -on: [push] +on: + push: + tags: + - "v*" jobs: build: @@ -16,6 +19,9 @@ jobs: key: ${{ runner.os }}-resources - name: Build test run: hugo --minify + - uses: docker/metadata-action@v5 + with: + images: ${{ vars.CONTAINER_REGISTRY_URL }}/${{ gitea.repository }} - uses: docker/login-action@v3 with: registry: ${{ vars.CONTAINER_REGISTRY_URL }} @@ -25,4 +31,5 @@ jobs: with: context: . push: true - tags: ${{ vars.CONTAINER_REGISTRY_URL }}/${{ gitea.repository }}:latest + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }}