From bec45cbde74d005239c4ffa844b595cad70f7aef Mon Sep 17 00:00:00 2001 From: GyulyVGC Date: Sat, 3 May 2025 11:09:30 +0200 Subject: [PATCH] update docker.yml --- .github/workflows/docker.yml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 35afb8d6..864d8dd1 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -1,6 +1,9 @@ name: Docker on: + push: + tags: + - 'v[0-9]+.[0-9]+.[0-9]+' workflow_dispatch: jobs: @@ -11,12 +14,12 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Extract version from Cargo.toml - id: cargo-version - run: | - VERSION=v$(grep -m1 "^version" Cargo.toml | cut -d'"' -f2) - echo "VERSION=$VERSION" >> $GITHUB_ENV - echo "version=$VERSION" >> $GITHUB_OUTPUT + # - name: Extract version from Cargo.toml + # id: cargo-version + # run: | + # VERSION=v$(grep -m1 "^version" Cargo.toml | cut -d'"' -f2) + # echo "VERSION=$VERSION" >> $GITHUB_ENV + # echo "version=$VERSION" >> $GITHUB_OUTPUT - name: Set up QEMU uses: docker/setup-qemu-action@v3 @@ -35,8 +38,8 @@ jobs: uses: docker/build-push-action@v5 with: context: . - platforms: linux/amd64,linux/arm64 + platforms: linux/amd64 push: true tags: | ghcr.io/gyulyvgc/sniffnet:latest - ghcr.io/gyulyvgc/sniffnet:${{ env.VERSION }} + ghcr.io/gyulyvgc/sniffnet:${{ github.ref_name }}