Running on different processors.
WHY THIS ARISES
Servers are commonly one architecture, and many laptops now another.
WHAT THE PROBLEM IS
An image built for one will not run on the other.
WHAT THE SYMPTOM IS
An error about exec format, or extremely slow performance under emulation.
WHAT A MULTI-ARCHITECTURE IMAGE IS
One tag pointing at several images, one per architecture.
HOW THE RIGHT ONE IS CHOSEN
The client requests what it can run.
HOW TO BUILD ONE
Build tooling that produces several and publishes an index.
WHAT THE OPTIONS ARE
Building natively on each architecture Emulating the other during the build
WHAT EMULATION COSTS
Build times several times longer.
WHAT NATIVE BUILDING REQUIRES
Machines of each architecture in the pipeline.
WHAT TO CHECK ABOUT DEPENDENCIES
That they are available for both.
WHY
Some compiled dependencies are not.
WHAT TO TEST
The image on each architecture, actually running.
WHY
A build succeeding does not mean it works.
WHAT TO DO IF ONLY ONE IS NEEDED
Build only that one, and say so clearly.
WHAT TO BE CAREFUL WITH
Developers on one architecture and production on another.
WHY
Behaviour differences surface in production only.