mirror of
https://github.com/maptiler/tileserver-gl.git
synced 2024-11-24 14:02:18 +03:00
2a94190bd1
* update to maplibre-gl-native 5.3.0-pre.0 * use ubuntu:jammy * use node 20 in docker image * update max node version to 20 * update docs to reflect new requirements * fix: update workflows to ubuntu-22.04 Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> * chore: update to maplibre-gl-native 5.3.0 Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> * chore: update version Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> * docs: update OS/package information Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> * fix: require node-addon-api ^7 Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> * fix: update package-lock.json Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net> --------- Signed-off-by: Andrew Calcutt <acalcutt@techidiots.net>
53 lines
1.4 KiB
Plaintext
53 lines
1.4 KiB
Plaintext
FROM ubuntu:jammy
|
|
|
|
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 \
|
|
curl \
|
|
gnupg; \
|
|
mkdir -p /etc/apt/keyrings; \
|
|
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg; \
|
|
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list; \
|
|
apt-get -qq update; \
|
|
apt-get install -y nodejs; \
|
|
npm i -g npm@latest; \
|
|
apt-get -y remove curl gnupg; \
|
|
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 config set maxsockets 1; \
|
|
npm config set fetch-retries 5; \
|
|
npm config set fetch-retry-mintimeout 100000; \
|
|
npm config set fetch-retry-maxtimeout 600000; \
|
|
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 |