diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 3bc088a..544f0eb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -30,7 +30,14 @@ jobs: docker build -t sdr-scanner . - name: Test sdr-scanner run: docker run --rm sdr-scanner-test - - name: Deploy sdr-scanner + - name: Deploy sdr-scanner branch + if: github.ref_type == 'branch' && github.event_name != 'pull_request' + run: | + TAG=${GITHUB_REF_NAME} + docker login -u ${{ secrets.DOCKER_HUB_USERNAME }} -p ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} docker.io + docker buildx create --use || true + docker buildx build --platform linux/arm/v7,linux/arm64/v8,linux/amd64 -t docker.io/shajen/sdr-scanner:$TAG --push . + - name: Deploy sdr-scanner tag if: github.ref_type == 'tag' run: | TAG=${GITHUB_REF_NAME/v/}