erlang / docker-erlang-otp

the Official Erlang OTP image on Docker Hub

Home Page:https://hub.docker.com/_/erlang/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dockerfiles for running Erlang on Alpine on Raspberry PI

jfacorro opened this issue · comments

I have a couple of these already build and published here. I could make a PR if there's interest.

commented

as I compared the Dockerfile, the only difference seems to be the base image, and you're based off arm32v6/alpine ? maybe the only thing in your PR is to https://github.com/docker-library/official-images/blob/master/library/erlang#L17 make the Architectures line has arm32v6 together with amd64, and since you have the hardware, would you like to test if arm32v7, arm64v8 also works?

please be aware from https://github.com/docker-library/official-images#architectures-other-than-amd64 the arm32v7 is the preferred Architecture of all arm based

➸ git diff c0b/master:20/alpine/Dockerfile jfacorro/master:20/armhf-alpine/Dockerfilediff --git a/origin/master:20/alpine/Dockerfile b/jfacorro/master:20/armhf-alpine/Dockerfile
index 281c9fd..e90561d 100644
--- a/origin/master:20/alpine/Dockerfile
+++ b/jfacorro/master:20/armhf-alpine/Dockerfile
@@ -1,8 +1,8 @@
-FROM alpine:3.6
+FROM arm32v6/alpine:3.6
 
 ENV OTP_VERSION="20.1.1"
 
 RUN set -xe \
        && OTP_DOWNLOAD_URL="https://github.com/erlang/otp/archive/OTP-${OTP_VERSION}.tar.gz" \
        && OTP_DOWNLOAD_SHA256="1f997c0c8aaa6217dcfc1dc0901717438cb2b63d4c20191f0d3d5c1bf61d4d5c" \
        && apk add --no-cache --virtual .fetch-deps \

for the erlang:19 I do not have erlang:19-alpine for amd64 either, since this June 2017 was the first time I added support for alpine flavor, I decided to add for the new versions only, not for 19 18 17 because since new version come out, the older versions will have fewer and fewer users, the marginal benefits will be little; so do not maintain erlang:alpine for older versions keep the maintenance as minimum; so are you sure you want to use alpine:19 alpine version on arm32v6 ? and arm32v7 arm64v8
https://github.com/jfacorro/docker-erlang-otp/blob/master/19/armhf-alpine/Dockerfile

Thank you for your feedback. I have a RPi 3 with ARMv7 but there is currently an image pushed to the hub for alpine in the arm32v7. I tried with the one in arm64v8 but it didn't work.

I will remove the Dockerfile for OTP 19 and check if I can get an image published for alpine in the arm32v7 repository.

commented

if you can verify this same Dockerfile working for alpine arm32v7, maybe you can send a PR to add arm32v7 to this file? this only arch missing for alpine is the arm32v7, because when multiarch support was added in #70 the erlang-20 alpine arm32v7 combination did not work; by now maybe things have changed, I do have a RP3 board using arm64v8 mode, it's 64bit vs 32bit difference so these two architecture are not compatibile, same like amd64 images won't work on i386.

https://github.com/docker-library/official-images/blob/master/library/erlang#L16-L19

If merged, then the official image will build and you can enjoy with the docker pull erlang:alpine on arm32v7 directly

I see this issue is a bit old, but I'm able to build the OTP 20 and 21 alpine images with the Dockerfiles here in this repository on a Raspberry Pi 3B+ with arm32v7 without any modifications.

commented

thanks for that confirmation; we will try add again arm32v7 for OTP 20+, if that can pass DockerHub's CI builds, will be pushed to official-images