forked from hexlet-codebattle/codebattle
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
32 lines (23 loc) · 749 Bytes
/
Dockerfile
File metadata and controls
32 lines (23 loc) · 749 Bytes
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
FROM elixir:1.5
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install --assume-yes apt-utils
RUN apt-get update && apt-get upgrade -y && \
apt-get install -y wget curl inotify-tools git build-essential zip unzip && \
apt-get clean && rm -fr /var/lib/apt/lists/* /tmp/* /var/tmp/*
RUN mix local.hex --force \
&& mix local.rebar --force
# Install Node and NPM
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash -
RUN apt-get install -y -q nodejs
WORKDIR /app
# install mix deps
ADD ./mix.exs /app
ADD ./mix.lock /app
RUN mix deps.get
# install npm deps
ADD ./assets/package.json /app/assets/
ADD ./assets/package-lock.json /app/assets/
RUN cd ./assets && \
npm install && \
cd ../
RUN mix compile