tomazzlender

tomazzlender

Elixir docker image won't build for linux/arm64/v8 using Github Actions

I setup a sample project on Github to show you a concrete example of a problem I’m having.

When I use

the build fails. The same happens if I use Elixir 1.14.0, but a different error.

You can see errors on the links above.

If I use the same Dockerfile on Mac M2 or Raspberry PI (aarm64 architecture), the build succeeds.

I’m not sure what could be the issue.

The build also succeeds

  • if I use Github Actions but some other architecture.
  • if I use Elixir 1.13.4

Any idea would be much appreciated :pray:.

Marked As Solved

jhogberg

jhogberg

Erlang Core Team

I’ll see if I can make a PR that fixes this in QEMU, it doesn’t seem to be a very high priority for them.

For the time being you can disable the JIT by compiling Erlang with ./configure --disable-jit.

Also Liked

yuriploc

yuriploc

Every time I forget about this I end up reading this post and also this one: BEAM docker release GitHub action - a GitHub action to build a docker container from a BEAM (Elixir/Erlang) release - #2 by asabil - Libraries - Erlang Programming Language Forum - Erlang Forums

TL;DR, adding ERL_FLAGS="+JPperf true" to your env vars should solve the issue with QEMU when building for linux/arm64 on a linux/amd64 host.

jhogberg

jhogberg

Erlang Core Team

As a small update, the patch for user-mode emulated AArch64 has been accepted and will most likely make it into the next major version of QEMU.

x86-64 is not covered by the patch, and may take much longer to get in if it’s accepted at all, as the workaround might not be as palatable (invalidating all translated code everywhere on serializing instructions like cpuid).

Where Next?

Popular in Questions Top

pgiesin
This should be a simple problem but I just can’t seem to figure it out. I have a standalone Elixir app that won’t find the database. Dep...
New
ycv005
I have followed this StackOverflow post to install the specific version of Erlang. And When I am running mix ecto.setup then getting fol...
New
Werner
Hi, I’m using Ubuntu 18.04 and after updating to OTP-24.0 yesterday i have this warning when I run “mix local.hex”: 14:57:30.512 [warn] ...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
mgjohns61585
Could someone help me? I'm making my first elixir program, number guessing game. I can't figure out how to convert the user's guess from ...
New
electic
Hi, I am new to Elixir. I am trying to use the DateTime component to insert a date into MySQL however the there seems to be no way to fo...
New
chrisalley
ExUnit now has describe blocks which is a welcome addition coming from RSpec. In the docs, it states that nested hierarchies of describe ...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers' Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
siddhant3030
Hi, I have to write a raw query for one of my project. But till now I have used ecto queries and don’t have much experience writing raw ...
New

Other popular topics Top

JorisKok
I have a server on AWS, and was running a load test using artillery. When looking at the Phoenix dashboard I see the Ports going to 100% ...
New
New
nsuchy
Hi. I’ve noticed that Windows Powershell has it’s own IEX command and you cannot access Elixir’s IEX due to the conflict. This isn’t a cr...
New
vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
lastday4you
I wanted to check elixir version in phoenix because i found that my elixir is 1.5 but when i use Enum.chunk_by it said the function is un...
New
myronmarston
The Elixir Typespec docs show the following syntax for keyword lists in typespecs: # ... | [key: type] # keyword lis...
New
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
josevalim
Hi everyone, One of the features added to Elixir early on to help integration with Erlang code was the idea of overridable function defi...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
Nvim
Elixir appears to be a superior language to Python. I don’t see any advantage of Python over Elixir. Are there any?
New

We're in Beta

About us Mission Statement