Skip to content

Instantly share code, notes, and snippets.

@brianmichel
Forked from DavidVII/codex_beam_bootstrap.sh
Created June 16, 2025 01:59
Show Gist options
  • Save brianmichel/ded3c6ba1faeafcff66b459343e6c6fb to your computer and use it in GitHub Desktop.
Save brianmichel/ded3c6ba1faeafcff66b459343e6c6fb to your computer and use it in GitHub Desktop.
Installing Elixir/Erlang on Codex
# Setup Versions
ERLANG_VERSION=27.3.4
ELIXIR_VERSION=1.18.3
# Setup asdf
go install github.com/asdf-vm/asdf/cmd/[email protected]
asdf plugin add erlang https://github.com/michallepicki/asdf-erlang-prebuilt-ubuntu-24.04.git || true
asdf plugin add elixir
asdf install erlang $ERLANG_VERSION
asdf set -u erlang $ERLANG_VERSION
asdf install elixir $ELIXIR_VERSION
asdf set -u elixir $ELIXIR_VERSION
export PATH=$HOME/.asdf/shims:$PATH
mix archive.install --force github hexpm/hex branch latest
install -Dm644 "$CODEX_PROXY_CERT" /usr/local/share/ca-certificates/codex-proxy.crt
update-ca-certificates
rm -rf deps _build mix.lock ~/.hex/cache
export ERL_SSL_CACERTFILE=/etc/ssl/certs/ca-certificates.crt
export HEX_CACERTS_PATH=/etc/ssl/certs/ca-certificates.crt
export HEX_MIRROR="https://cdn.jsdelivr.net/hex"
export HEX_CDN="https://cdn.jsdelivr.net/hex"
export HEX_HTTP_CONCURRENCY=1
export HEX_HTTP_TIMEOUT=600000
mix deps.get
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment