diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1a92383..b2d1d09 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -29,8 +29,6 @@ jobs: # python3 -m pytest --import-mode=append tests/ build-main: - # if: github.ref == 'refs/heads/main' - # needs: unit-tests runs-on: ubuntu-latest defaults: run: @@ -39,6 +37,12 @@ jobs: - name: 'Checkout GitHub Action' uses: actions/checkout@main + - name: Set up QEMU + uses: docker/setup-qemu-action@v1 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: 'Login to GitHub Container Registry' uses: docker/login-action@v1 with: @@ -62,16 +66,14 @@ jobs: IMAGE_NAME: ghcr.io/manimatter/decluttarr IMAGE_TAG: ${{ steps.setversion.outputs.new_tag }} run: | - docker build -f docker/Dockerfile -t $IMAGE_NAME:$IMAGE_TAG . - docker push $IMAGE_NAME:$IMAGE_TAG + docker buildx build --platform linux/amd64,linux/arm64 -t $IMAGE_NAME:$IMAGE_TAG -f docker/Dockerfile --push . - name: "Build, Tag, and push the Docker image" env: IMAGE_NAME: ghcr.io/manimatter/decluttarr IMAGE_TAG: latest run: | - docker build -f docker/Dockerfile -t $IMAGE_NAME:$IMAGE_TAG . - docker push $IMAGE_NAME:$IMAGE_TAG + docker buildx build --platform linux/amd64,linux/arm64 -t $IMAGE_NAME:$IMAGE_TAG -f docker/Dockerfile --push . # build-dev: # if: github.ref == 'refs/heads/dev'