-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
34 lines (23 loc) · 823 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
FROM bitwalker/alpine-elixir:1.8.1
RUN mkdir -p /opt/app && \
chmod -R 777 /opt/app && \
apk --no-cache --update add \
nodejs yarn inotify-tools libressl libressl-dev zlib zlib-dev
# Copy the watchman executable binary directly from our image:
COPY --from=icalialabs/watchman:4-alpine3.4 /usr/local/bin/watchman* /usr/local/bin/
# Create the watchman STATEDIR directory:
RUN mkdir -p /usr/local/var/run/watchman \
&& touch /usr/local/var/run/watchman/.not-empty
# Don't do this at home
RUN ln -s /lib/libcrypto.so.1.1 /lib/libcrypto.so.1.0.0
ENV MIX_HOME=/opt/mix \
HEX_HOME=/opt/hex \
HOME=/opt/app
# Install Hex+Rebar
RUN mix local.hex --force && \
mix local.rebar --force
WORKDIR /opt/app
ENV PORT 4000
ONBUILD COPY . .
EXPOSE ${PORT}
CMD ["mix", "do", "deps.get", ",", "phx.server"]