mirror of
https://github.com/correl/docker-pleroma.git
synced 2024-12-27 11:09:51 +00:00
3baf998bb6
As of [recently](58b12c09db
) Pleroma requires Elixir 1.7.
32 lines
661 B
Docker
32 lines
661 B
Docker
FROM elixir:1.7-alpine
|
|
|
|
ENV UID=911 GID=911 \
|
|
MIX_ENV=prod
|
|
|
|
ARG PLEROMA_VER=develop
|
|
|
|
RUN apk -U upgrade \
|
|
&& apk add --no-cache \
|
|
build-base \
|
|
git
|
|
|
|
RUN addgroup -g ${GID} pleroma \
|
|
&& adduser -h /pleroma -s /bin/sh -D -G pleroma -u ${UID} pleroma
|
|
|
|
USER pleroma
|
|
WORKDIR pleroma
|
|
|
|
RUN git clone -b develop https://git.pleroma.social/pleroma/pleroma.git /pleroma \
|
|
&& git checkout ${PLEROMA_VER}
|
|
|
|
COPY config/secret.exs /pleroma/config/prod.secret.exs
|
|
|
|
RUN mix local.rebar --force \
|
|
&& mix local.hex --force \
|
|
&& mix deps.get \
|
|
&& mix compile
|
|
|
|
RUN mkdir /pleroma/uploads
|
|
VOLUME /pleroma/uploads/
|
|
|
|
CMD ["mix", "phx.server"]
|