Treating the problem “WARNING: The requested image’s platform (linux/arm64) does not match the detected host platform (linux/amd64) and no specific platform was requested”

Error

This post is intended for DevOps professionals who have encountered the following issue while running a container that uses PHP:

WARNING: The requested image's platform (linux/arm64) does not match the detected host platform (linux/amd64) and no specific platform was requested. standard_init_linux.go:228: exec user process caused: exec format error

The error occurs when using docker run, for example:

docker run - rm -p 9000:9000 1234567.dkr.ecr.us-east-1.amazonaws.com/devops-mind:php-1

Solution

It was necessary to build the PHP image from a Linux workstation instead of macOS.

Fernando Müller Junior
Fernando Müller Junior

I am Fernando Müller, a Tech Lead SRE with 16 years of experience in IT, I currently work at Appmax, a fintech located in Brazil. Passionate about working with Cloud Native architectures and applications, Open Source tools and everything that exists in the SRE world, always looking to develop and learn constantly (Lifelong learning), working on innovative projects!

Articles: 28

Leave a Reply

Your email address will not be published. Required fields are marked *