DEV Community

Cover image for Build Arm Docker images five times faster on native hardware
Jim Sheldon for Harness

Posted on

Build Arm Docker images five times faster on native hardware

The ARMv8 (a.k.a. ARM64) CPU architecture, announced 12 years ago, was the first Arm architecture to support a 64-bit instruction set. Apple famously introduced its ARM64-based M1 chip in November of 2020. In June of this year, Apple completed its transition away from Intel-based CPUs by launching a new Mac Pro model powered by the M2 revision of the chip. In the PC market, Arm notebooks are expected to increase to 27% market share by 2027. In the cloud computing space, all major service providers offer Arm solutions.

We have entered a world where Arm can’t be ignored. If your company isn’t adapting your applications and running infrastructure on Arm, chances are your competition is.

Cost and Energy Savings with Arm

The Arm architecture offers significant potential cost and energy savings. A recent study showed that moving to Arm-based cloud infrastructure can achieve up to 40% better performance per dollar over comparable Intel-based infrastructure.

Companies like Squeaky reduced their cloud spending by 35% by switching to Arm. When analyzing CPU, memory, and latency metrics after the migration, Squeaky reports "no performance degradation" on the new hardware.

Database company Aerospike saw annual costs decrease by an estimated 27% after switching to Graviton2 processors on AWS EC2. They also cut carbon emissions by an estimated 49% while achieving aggressive targets for transaction throughput and data access latency.

Docker and Arm

The 2022 StackOverflow Developer Survey found that Docker is becoming a "fundamental tool for Professional Developers, increasing from 55% to 69%." According to the CNCF 2022 annual survey, 44% of respondents use containers for nearly all applications and business segments, and another 35% say they use containers for at least a few production applications.

This means that the first challenge many companies face when adopting Arm is how to build their application containers for this different architecture. While Docker supports building images for other CPU architectures under emulation, this can significantly impact performance.

Native Builds vs. Emulation

To visualize the difference in performance, we built base Docker images for Python, Ruby, HAProxy and Redis using both emulation and native ARM64 hardware.

This graph shows build time in minutes for native Arm hardware compared to emulation 1.

Docker image build times

These results show builds completed five times faster on average with native Arm hardware. This is valuable time your developers could be using for development, rather than waiting for pipelines.

While Arm clearly has incredible momentum, some companies in the continuous integration space have been slow to provide hosted resources.

Comment for #5631

mfittko avatar
mfittko commented on

It's just way more convenient to work with arm based images and not having to deal with multi arch, if you have an ARM based mac, so big +1 here, too ;) it would just be so much more sustainable to be able to work and build for a single platform (of choice) - think of the environment! All these wasted cpu cycles!

Here at Harness, Arm infrastructure has been available in Harness CI Cloud since the beginning.

To sign up for Harness Cloud and get 2,000 free monthly build credits for your pipelines, see the original blog post for this article.


  1. Tested with minimum 4 vCPUs and 16GB memory 

Top comments (0)