diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d619a16752e644e0b82bd2cd566b1b34d6d9ce3c..b3e0c09001d0324a64f5b8abf594a2b7e3392361 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -96,12 +96,13 @@ build: - "$DOCKER_DIND_IMAGE" image: "$DOCKER_DIND_IMAGE" before_script: - # Install buildx - - mkdir -p ~/.docker/cli-plugins - - wget "https://github.com/docker/buildx/releases/download/v$BUILDX_VERSION/buildx-v$BUILDX_VERSION.linux-amd64" -O ~/.docker/cli-plugins/docker-buildx - - chmod a+x ~/.docker/cli-plugins/docker-buildx - # See https://www.docker.com/blog/multi-platform-docker-builds/ - - docker run --rm --privileged docker/binfmt:a7996909642ee92942dcd6cff44b9b95f08dad64 + # See https://docs.docker.com/build/building/multi-platform/#qemu + # To be able to build for arm64 which is not native to hosted runners, + # we need to inject a stub for being able to do so. + # + # The container below is used by the docs article above and hence + # considered upstream, even though it's in a non-Docker namespace. + - docker run --rm --privileged tonistiigi/binfmt # Registry auth - docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY" script: