Exposes port on built image
This commit is contained in:
parent
bf11cd0dd9
commit
0147b60840
1 changed files with 4 additions and 1 deletions
|
|
@ -75,6 +75,8 @@ RUN mix release
|
||||||
# the compiled release and other runtime necessities
|
# the compiled release and other runtime necessities
|
||||||
FROM ${RUNNER_IMAGE}
|
FROM ${RUNNER_IMAGE}
|
||||||
|
|
||||||
|
ARG PORT=8945
|
||||||
|
|
||||||
RUN apt-get update -y
|
RUN apt-get update -y
|
||||||
RUN apt-get install -y libstdc++6 openssl libncurses5 locales ca-certificates \
|
RUN apt-get install -y libstdc++6 openssl libncurses5 locales ca-certificates \
|
||||||
ffmpeg curl git openssh-client nano
|
ffmpeg curl git openssh-client nano
|
||||||
|
|
@ -101,8 +103,9 @@ RUN chown nobody /config /downloads
|
||||||
|
|
||||||
# set runner ENV
|
# set runner ENV
|
||||||
ENV MIX_ENV="prod"
|
ENV MIX_ENV="prod"
|
||||||
ENV PORT=8945
|
ENV PORT=${PORT}
|
||||||
ENV RUN_CONTEXT="selfhosted"
|
ENV RUN_CONTEXT="selfhosted"
|
||||||
|
EXPOSE ${PORT}
|
||||||
|
|
||||||
# Only copy the final release from the build stage
|
# Only copy the final release from the build stage
|
||||||
COPY --from=builder --chown=nobody:root /app/_build/${MIX_ENV}/rel/pinchflat ./
|
COPY --from=builder --chown=nobody:root /app/_build/${MIX_ENV}/rel/pinchflat ./
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue