-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile
43 lines (22 loc) · 852 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
35
36
37
38
39
40
41
42
43
FROM node:12 as FRONTEND-BUILDER
RUN sed -i 's/stable\/updates/stable-security\/updates/' /etc/apt/sources.list
RUN apt-get update && apt-get install -y git
WORKDIR /app
RUN git clone https://github.com/ClassAxion/parrot-disco-dashboard-frontend /app
RUN npm i
RUN npm run build
FROM node:16 as BACKEND
RUN apt-get update && apt-get install -y git ffmpeg
WORKDIR /app
RUN git clone https://github.com/ClassAxion/disco-4g-without-sc2 /app
RUN npm i
RUN npm run build
CMD ["npm","run","start"]
FROM nginx:1.15-alpine as FRONTEND
COPY --from=FRONTEND-BUILDER /app/dist /usr/share/nginx/html
COPY ./nginx/nginx-default.conf.template /etc/nginx/conf.d/default.conf.template
COPY ./nginx/docker-entrypoint.sh /
EXPOSE 80
RUN ["chmod", "+x", "/docker-entrypoint.sh"]
ENTRYPOINT ["/docker-entrypoint.sh"]
CMD ["nginx", "-g", "daemon off;"]