From 3d0ee47aa28cb3814c983f5fa76780e2e8cf2691 Mon Sep 17 00:00:00 2001 From: ttionya Date: Fri, 13 Sep 2024 00:57:53 +0800 Subject: [PATCH] build: fix docker release build - fixes #8062 This updates the action to use `docker/build-push-action` instead of `ilteoood/docker_buildx` which fixes the build problem in testing. --- .../build_publish_release_docker_image.yml | 28 +++++++++++++------ 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build_publish_release_docker_image.yml b/.github/workflows/build_publish_release_docker_image.yml index 319ce1b30..b69285a7e 100644 --- a/.github/workflows/build_publish_release_docker_image.yml +++ b/.github/workflows/build_publish_release_docker_image.yml @@ -32,15 +32,27 @@ jobs: - name: Get actual major version id: actual_major_version run: echo ::set-output name=ACTUAL_MAJOR_VERSION::$(echo $GITHUB_REF | cut -d / -f 3 | sed 's/v//g' | cut -d "." -f 1) - - name: Build and publish image - uses: ilteoood/docker_buildx@1.1.0 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - name: Login to Docker Hub + uses: docker/login-action@v3 with: - tag: latest,${{ steps.actual_patch_version.outputs.ACTUAL_PATCH_VERSION }},${{ steps.actual_minor_version.outputs.ACTUAL_MINOR_VERSION }},${{ steps.actual_major_version.outputs.ACTUAL_MAJOR_VERSION }} - imageName: rclone/rclone - platform: linux/amd64,linux/386,linux/arm64,linux/arm/v7,linux/arm/v6 - publish: true - dockerHubUser: ${{ secrets.DOCKER_HUB_USER }} - dockerHubPassword: ${{ secrets.DOCKER_HUB_PASSWORD }} + username: ${{ secrets.DOCKER_HUB_USER }} + password: ${{ secrets.DOCKER_HUB_PASSWORD }} + - name: Build and publish image + uses: docker/build-push-action@v6 + with: + file: Dockerfile + context: . + platforms: linux/amd64,linux/386,linux/arm64,linux/arm/v7,linux/arm/v6 + push: true + tags: | + rclone/rclone:latest + rclone/rclone:${{ steps.actual_patch_version.outputs.ACTUAL_PATCH_VERSION }} + rclone/rclone:${{ steps.actual_minor_version.outputs.ACTUAL_MINOR_VERSION }} + rclone/rclone:${{ steps.actual_major_version.outputs.ACTUAL_MAJOR_VERSION }} build_docker_volume_plugin: if: github.repository == 'rclone/rclone'