-
Notifications
You must be signed in to change notification settings - Fork 79
/
Copy pathDockerfile
44 lines (37 loc) · 995 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
44
FROM ubuntu:17.10
LABEL maintainer="Huan LI <zixia@zixia.net>"
ENV DEBIAN_FRONTEND noninteractive
ENV LC_ALL C.UTF-8
RUN apt-get update && apt-get install -y \
build-essential \
curl \
g++ \
git \
iputils-ping \
libcairo2-dev \
libjpeg8-dev \
libpango1.0-dev \
libgif-dev \
python2.7 \
python3.6 \
python3.6-dev \
python3-venv \
sudo \
tzdata \
vim \
&& rm -rf /var/lib/apt/lists/*
RUN curl -sL https://deb.nodesource.com/setup_9.x | bash - \
&& apt-get update && apt-get install -y nodejs \
&& rm -rf /var/lib/apt/lists/*
RUN mkdir /facenet /workdir
WORKDIR /facenet
COPY . .
RUN npm install --unsafe-perm \
&& npm run dist \
&& sudo ln -s /usr/lib/node_modules /node_modules \
&& sudo ln -s /facenet/node_modules/* /node_modules/ \
&& sudo ln -s /facenet /node_modules/facenet \
&& sudo rm -fr /tmp/* ~/.npm
# EXPOSE 80
VOLUME [ "/workdir" ]
CMD [ "npm", "start" ]