40 lines
1003 B
Docker
40 lines
1003 B
Docker
|
FROM node:10-alpine
|
||
|
ARG VERSION
|
||
|
ENV VERSION ${VERSION:-development}
|
||
|
|
||
|
RUN echo "http://dl-cdn.alpinelinux.org/alpine/edge/main" > /etc/apk/repositories \
|
||
|
&& echo "http://dl-cdn.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
|
||
|
&& echo "http://dl-cdn.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \
|
||
|
&& echo "http://dl-cdn.alpinelinux.org/alpine/v3.11/main" >> /etc/apk/repositories \
|
||
|
&& apk upgrade -U -a \
|
||
|
&& apk add --no-cache --virtual .gyp\
|
||
|
libstdc++ \
|
||
|
libjpeg \
|
||
|
chromium \
|
||
|
harfbuzz \
|
||
|
nss \
|
||
|
freetype \
|
||
|
ttf-freefont \
|
||
|
wqy-zenhei \
|
||
|
python make g++ \
|
||
|
pixman \
|
||
|
&& rm -rf /var/cache/* \
|
||
|
&& mkdir /var/cache/apk
|
||
|
|
||
|
WORKDIR /app
|
||
|
|
||
|
COPY start.sh package.json *.js settings.json ecosystem.config.json /app/
|
||
|
COPY lib/ /app/lib
|
||
|
COPY scrapers/ /app/scrapers
|
||
|
COPY pug/ /app/pug
|
||
|
|
||
|
RUN npm install pm2 -g && npm install
|
||
|
|
||
|
# RUN npm install
|
||
|
|
||
|
# COPY start.sh /app/
|
||
|
|
||
|
RUN chmod +x /app/start.sh
|
||
|
|
||
|
ENTRYPOINT ["/app/start.sh"]
|