Container App fails to start up with "standard_init_linux.go:228: exec user process caused: exec format error"

Viewed 2338

Was using Azure Container Apps and on deploy the command failed to provision the container and told me to check log analytics. When I checked I only see a single log from the container that says:

standard_init_linux.go:228: exec user process caused: exec format error

What's the issue here?

1 Answers

This error can happen when the arch of the docker image doesn't match the runtime environment. Azure Container Apps runs on amd64 arch, and I built and published these docker containers from a Mac M1 ARM processor. I had two options here:

  1. Use features like docker buildx build --platform linux/amd64 to emulator an amd64 and publish a version there
  2. Use some remote build (like GitHub Actions) to build the container on an arch that matches Azure Container Apps environment
Related