Browse Source

Runtime-stage fixes

master
buttercat1791 2 months ago
parent
commit
5b09d186e1
  1. 11
      Dockerfile

11
Dockerfile

@ -4,6 +4,11 @@ ARG DEBIAN_VERSION=trixie-20260202-slim
FROM "docker.io/hexpm/elixir:${ELIXIR_VERSION}-erlang-${OTP_VERSION}-debian-${DEBIAN_VERSION}" FROM "docker.io/hexpm/elixir:${ELIXIR_VERSION}-erlang-${OTP_VERSION}-debian-${DEBIAN_VERSION}"
# Set the locale
ENV LANG=en_US.UTF-8
ENV LANGUAGE=en_US:en
ENV LC_ALL=en_US.UTF-8
# Install dependencies # Install dependencies
RUN apt-get update \ RUN apt-get update \
&& apt-get install -y --no-install-recommends build-essential make gcc erlang-dev git autoconf automake libtool pkg-config \ && apt-get install -y --no-install-recommends build-essential make gcc erlang-dev git autoconf automake libtool pkg-config \
@ -14,6 +19,7 @@ WORKDIR /app
COPY . . COPY . .
# Compile the application # Compile the application
ENV MIX_HOME=/app/.mix
RUN mix local.hex --force && mix local.rebar --force RUN mix local.hex --force && mix local.rebar --force
RUN mix deps.get --only prod RUN mix deps.get --only prod
RUN MIX_ENV=prod mix compile RUN MIX_ENV=prod mix compile
@ -21,11 +27,6 @@ RUN MIX_ENV=prod mix compile
# Update the static Swagger documentation # Update the static Swagger documentation
RUN MIX_ENV=prod mix phx.swagger.generate RUN MIX_ENV=prod mix phx.swagger.generate
# Set the locale
ENV LANG=en_US.UTF-8
ENV LANGUAGE=en_US:en
ENV LC_ALL=en_US.UTF-8
# Run as the isidore-dev user # Run as the isidore-dev user
USER 1008 USER 1008

Loading…
Cancel
Save