github actions: standard_init_linux.go:211: exec user process caused "exec format error"


When running my Dockerfile in github actions I get the error:

standard_init_linux.go:211: exec user process caused “exec format error”

What is going on and can I build and deploy another way?

Hi Max,

Can you please explain what are you trying to achieve in a bit more detail? Are you using balenaCloud? Have you checked the getting started guide for balena? Normally you would just do balena push and our builder will build your image for the appropriate architecture, and your device will pull the latest image and run it. Once you provide us with a bit more information on what you are trying to achieve, we can talk on how to progress further.


Basically installing opencv on a raspberry pi takes absolutely ages so I wanted to create a container so that I can pull it from the raspberry pi.

I am not using balenaCloud I am just using the balenalib/raspberrypi3-debian:latest



I see, you are just using our base image then. The reason this is failing is because you are trying to run arm binaries on x86, which wouldn’t work. You will have to run an emulated build for the image to be built for arm instead. You will need to update binfmt_misc for it to work. It is quite detailed, and it should give you an idea how to make it work: Let us know how it goes.

I tried running this on an arm64 instance but still get the same error :frowning:

Hello, this image (balenalib/raspberrypi3-debian) is compiled for armv7hf, I don’t think it can run on “an arm64 instance”.