For a recent robotics project I had to run a ROS/Gazebo pipeline that was based on a pre-built x86/amd64 docker image.
I do most of my local development work on an M1 Mac. The M1 is an ARM based processor, so the question was how to get the stack to run. Unfortunately Docker for Mac was not an option, because it wouldn’t run Gazebo properly. Therefore I knew that I had to go with Linux and somewhere between the OS and the Docker I needed something (qemu or similar) to go from the x86 to the ARM instruction set.
The real breakthrough was the realization that if you use Apple’s virtualization framework to run a Linux VM you can use Rosetta (Apple’s own processor translation layer) within that VM and this this blogpost helped tremendously.
Maybe I will do a follow-up on how exactly I made it work, but the basic setup is: Debian12 in a VM (utilizing Apple Virtualization in UTM https://getutm.app) and then execute the x86/amd64 docker image with Rosetta and I am still amazed that this works.



