Run a 32-bit binary on Google Cloud Run

The title say it all. I need a way to run a 32-bit binary on Cloud Run, which seems to only support 64-bit

What I'm looking for is some sort of emulator or compatibility layer that I could install.

I cannot compile the program to 64-bits.


Solution 1:

I found the program I was looking for, which is qemu.

After you add apt install -y qemu-user to your Dockerfile you can run a 32-bit binary with the command qemu-i386 ./file 🎉

I hope one day someone comes across this question & answer and finds it useful.