I used to be able to download openjdk:8-jdk-slim as below
docker run -it --name my-container openjdk:8-jdk-slim
After moving to Apple M1 MacBook Pro, I have to use this parameter --platform linux/amd64 as stated in https://docs.docker.com/docker-for-mac/apple-silicon/
docker run -it --platform linux/amd64 --name my-container openjdk:8-jdk-slim
But for a Dockerfile I have
FROM openjdk:8-jdk-slim
// Other codes
How can I add the needed parameter to it, so that the Dockerfile still work on my Apple M1 MacBook Pro?