-
Notifications
You must be signed in to change notification settings - Fork 20
/
Dockerfile
49 lines (43 loc) · 1.59 KB
/
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
45
46
47
48
49
FROM debian:12-slim
# https://serverfault.com/questions/949991/how-to-install-tzdata-on-a-ubuntu-docker-image
ARG DEBIAN_FRONTEND=noninteractive
# Style dependencies
RUN apt-get update \
&& apt-get install --no-install-recommends -y \
ca-certificates \
curl \
gnupg \
postgresql-client \
python3 \
python3-distutils \
fonts-hanazono \
fonts-noto-cjk \
fonts-noto-hinted \
fonts-noto-unhinted \
mapnik-utils \
nodejs \
npm \
fonts-unifont \
unzip \
git \
&& rm -rf /var/lib/apt/lists/* \
&& apt-get clean
# Kosmtik with plugins, forcing prefix to /usr because Ubuntu sets
# npm prefix to /usr/local, which breaks the install
# We install kosmtik not from release channel, but directly from a specific commit on github.
RUN npm set prefix /usr && npm install -g --unsafe-perm "git+https://[email protected]/kosmtik/kosmtik.git"
WORKDIR /usr/lib/node_modules/kosmtik/
RUN kosmtik plugins --install kosmtik-overpass-layer \
--install kosmtik-fetch-remote \
--install kosmtik-overlay \
--install kosmtik-open-in-josm \
--install kosmtik-map-compare \
--install kosmtik-osm-data-overlay \
--install kosmtik-mapnik-reference \
--install kosmtik-geojson-overlay \
&& cp /root/.config/kosmtik.yml /tmp/.kosmtik-config.yml
# Closing section
RUN mkdir -p /openrailwaymap
WORKDIR /openrailwaymap
USER 1000
ENTRYPOINT ["sh", "docker-startup.sh", "kosmtik"]