Docker Community Forums

Share and learn in the Docker community.

Docker AMD64 image on Raspberry PI 4 AARCH64

Hi All! :slight_smile:
I’m new to Docker and I want to run Java (Quarkus) application in Docker container on Raspberry PI 4.
Somehow I made it work and now I wonder how the pieces fit together, and why things work the way they work.
The scenario is as follows:

  1. My RPI is running Ubuntu Desktop 20.10 (64 bit):

Linux codo-pi 5.8.0-1013-raspi #16-Ubuntu SMP PREEMPT Thu Jan 14 06:28:38 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux

  1. I want to develop on Windows preferably without the virtual machine. I run Windows 10 PRO, Docker Desktop (WSL 2).
  2. My docker image (Docker Hub) is based on “balenalib/raspberry-pi-openjdk:8-stretch”
    (Note: docker image inspect balenalib/raspberry-pi-openjdk:8-stretch -f ‘{{.Os}}/{{.Architecture}}’

Question: How come there’s a raspberry pi image that utlises amd64 architecture?

  • My RPI is running podman: " OsArch: linux/arm64 Version: 2.0.6"
  • I run "podman run -i --rm -p 8080:8080 myimagehere "… and it works!:

INFO [io.quarkus] (main) rummager 1.0.0-SNAPSHOT on JVM (powered by Quarkus 1.11.0.Final) started in 5.718s. Listening on:

Is there any magic going on behind the scenes? Is this somehow specific to balena image ?

I’ve tried using arm64v8/adoptopenjdk image that looks to be truly arm64 based and it does not work on Windows (do it’d require using virtualization on my desktop):

docker pull arm64v8/adoptopenjdk
Using default tag: latest
latest: Pulling from arm64v8/adoptopenjdk
no matching manifest for linux/amd64 in the manifest list entries