docker-pleroma/Dockerfile
AndreVuillemot160 373e147cea
Fix permissions
If you don't fix permissions you aren't going to be able to have emojis and all that stuff. So this command is really important.
2021-07-22 22:30:20 +03:00

36 lines
692 B
Docker

FROM elixir:1.11.4-alpine
ENV UID=911 GID=911 \
MIX_ENV=prod
ARG PLEROMA_VER=develop
RUN apk -U upgrade \
&& apk add --no-cache \
build-base \
cmake \
git \
file-dev
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
VOLUME /pleroma/uploads/
RUN chown -R pleroma:pleroma ./
CMD ["mix", "phx.server"]