Docker doesn't really help with ARM/Intel differences. You need something like JVM for that.
[0] https://docs.docker.com/build/buildx/#build-multi-platform-i...
It also supports running other architecture images using the same QEMU magic. It's really quite polished and works well.
Docker does provide environment variables you can use to automatically download the right file depending on the target architecture, but the syntax is very cumbersome.
That said, yes using something on the JVM is much more convenient, but that’s not possible if you’re not using a JVM language.