forked from maptiler/tileserver-gl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile_light
44 lines (33 loc) · 954 Bytes
/
Dockerfile_light
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:focal
ENV \
NODE_ENV="production" \
CHOKIDAR_USEPOLLING=1 \
CHOKIDAR_INTERVAL=500
RUN set -ex; \
export DEBIAN_FRONTEND=noninteractive; \
groupadd -r node; \
useradd -r -g node node; \
apt-get -qq update; \
apt-get -y --no-install-recommends install \
ca-certificates \
wget; \
wget -qO- https://deb.nodesource.com/setup_18.x | bash; \
apt-get install -y nodejs; \
apt-get -y remove wget; \
apt-get -y --purge autoremove; \
apt-get clean; \
rm -rf /var/lib/apt/lists/*;
EXPOSE 8080
RUN mkdir -p /data; \
chown node:node /data; \
mkdir -p /usr/src/app;
VOLUME /data
WORKDIR /data
COPY / /usr/src/app
RUN cd /usr/src/app; \
npm install --omit=dev; \
chown -R root:root /usr/src/app; \
chmod +x /usr/src/app/docker-entrypoint.sh;
USER node:node
ENTRYPOINT ["/usr/src/app/docker-entrypoint.sh"]
HEALTHCHECK CMD node /usr/src/app/src/healthcheck.js