Multi-arch build, what about CircleCI?

December 8, 2025 · 385 words · 2 min

Following the where we saw how to build multi arch images using GitHub Actions, we will now show h

Following the where we saw how to build multi arch images using GitHub Actions, we will now show how to do the same thing using another CI. In this article, we’ll consider CircleCI, which is one of the most used CI SaaS. To start building your image with CircleCI, you will first need to create file: version: jobs:   build:     docker:       - image: docker:stable     steps:       -       - setup_remote_docker:           version:       - run: You may notice that we specified using version 18.09.3 of the Docker Engine because buildx requires version 18.09 or later but CircleCI doesn’t provide any version above 18.09.3. At this point we are able to interact with the Docker CLI but we don’t yet have the buildx plugin installed. To install it, we will download a build from GitHub. version: jobs:   build:     docker:       - image: docker:stable     steps:       -       - setup_remote_docker:           version:       - run:       - run:       - run: https://github.com/docker/buildx/releases/download/v0.3.1/buildx-v0.3.1.linux-amd64       - run:       - run: We are now able to use buildx. It’s quite verbose, so instead of reinstalling buildx each time you want to build something, you can use a different with buildx already installed. version: jobs: build:   docker:     - image:   steps:     -     - setup_remote_docker:         version:     - run: Now it’s time to build for multiple architectures. We’ll use the same Dockerfile that we used for the previous article and the same build command: debian:buster-slim apt-get update
  && apt-get install -y curl
  && rm -rf /var/lib/apt/lists/* [ ] Now modify the CircleCI configuration file as follows: version: jobs: build:   docker:     - image:   steps:     -     - setup_remote_docker:         version:     - run: Navigating to the CircleCI build dashboard, you should see the following result: The last step is now to store the image on the Docker Hub. To do so we’ll need an to get write access. Once you created it, you’ll have to set it in your repository settings in the section. We’ll create and variables to login afterward. Once this is done, you can add the login step and the to the buildx command as follows: version: jobs: build:   docker:     - image:   steps:     -     - setup_remote_docker:         version:     - run:     - run: And voila, you can now create a multi arch image each time you make a change in your codebase!