I highly recommend using the hexpm docker images, which you specify with elixir, erlang, and distro versions, e.g. hexpm/elixir1.12-erlang24.0-debian-buster.
Since the official Elixir versions aren't pinned to a version of Erlang, we had issues where either Erlang or the distro should change out from under us. But not with the hexpm ones.
I second this - it is the best solution if one wants to decouple upgrades of Elixir vs OTP, and is really useful for long term upgrades (one step at a time).