Run x86 (Intel) and ARM based images on Apple Silicon (M1) Macs?

You can run ARM or Intel Docker containers on the Apple M1 Mac with Docker Desktop for Mac M1. I do it all the time. The default, of course, is to run the ARM version but if you use the --platform linux/amd64 parameter Docker will run the Intel version for you.

You can try it with one of my images that I’ve built to run Vagrant with Docker as a provider on Apple M1 Silicon:

docker run --rm -it --platform linux/amd64 rofrano/vagrant-provider:debian bash

That will drop you into a bash shell in an amd64 container.

# uname -a
Linux 694817f598fe 5.10.47-linuxkit #1 SMP PREEMPT Sat Jul 3 21:50:16 UTC 2021 x86_64 GNU/Linux

BTW, I absolutely love my M1 Mac mini for development work. It is blazing fast! I highly recommend getting one.

If you want more info on how I built that image I documented it in this article:
Developing on Apple M1 Silicon with Virtual Environments

Hope that helps.

4 Likes