diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d0d741245..56ba05278 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -620,13 +620,23 @@ jobs: echo 'ghcr.io/prymitive/karma:latest' >> $GITHUB_ENV echo 'EOF' >> $GITHUB_ENV + - name: "Setup docker plaforms (merge/release)" + if: github.event_name != 'pull_request' + run: | + echo "DOCKER_PATFORMS=linux/amd64,linux/arm64" >> $GITHUB_ENV + + - name: "Setup docker plaforms (PR)" + if: github.event_name == 'pull_request' + run: | + echo "DOCKER_PATFORMS=linux/amd64" >> $GITHUB_ENV + - name: Build and push id: docker_build uses: docker/build-push-action@v2 with: context: . file: ./Dockerfile - platforms: linux/amd64,linux/arm64 + platforms: ${{ env.DOCKER_PATFORMS }} push: ${{ github.event_name != 'pull_request' }} tags: ${{ env.DOCKER_TAGS }} cache-from: type=local,src=/tmp/.buildx-cache