Fix Dockerfile with proper Erlang/Elixir installation

This commit is contained in:
Andreas Dueren
2025-06-20 07:57:45 -06:00
parent 4a1a5129f2
commit c15a7785ab

View File

@ -4,18 +4,18 @@ FROM cloudron/base:4.2.0
RUN mkdir -p /app/code /app/data RUN mkdir -p /app/code /app/data
WORKDIR /app/code WORKDIR /app/code
# Install Elixir and dependencies # Install Erlang and Elixir
RUN curl -fSL https://github.com/elixir-lang/elixir/releases/download/v1.15.7/elixir-otp-26.zip -o elixir.zip \ RUN apt-get update \
&& unzip elixir.zip -d /opt/elixir \ && apt-get install -y wget gnupg \
&& rm elixir.zip \ && wget https://packages.erlang-solutions.com/erlang-solutions_2.0_all.deb \
&& ln -s /opt/elixir/bin/* /usr/local/bin/ \ && dpkg -i erlang-solutions_2.0_all.deb \
&& apt-get update \ && apt-get update \
&& apt-get install -y erlang-dev erlang-parsetools erlang-xmerl elixir \
&& apt-get install -y git build-essential cmake nodejs npm postgresql-client \ && apt-get install -y git build-essential cmake nodejs npm postgresql-client \
&& rm -rf /var/lib/apt/lists/* && rm -rf /var/lib/apt/lists/* erlang-solutions_2.0_all.deb
# Set environment variables # Set environment variables
ENV MIX_ENV=prod ENV MIX_ENV=prod
ENV PATH="/opt/elixir/bin:$PATH"
# Clone and build Keila # Clone and build Keila
RUN git clone --depth 1 --branch v0.14.7 https://github.com/pentacent/keila.git . \ RUN git clone --depth 1 --branch v0.14.7 https://github.com/pentacent/keila.git . \