-
Notifications
You must be signed in to change notification settings - Fork 21
Expand file tree
/
Copy pathDockerfile
More file actions
47 lines (40 loc) · 1.22 KB
/
Dockerfile
File metadata and controls
47 lines (40 loc) · 1.22 KB
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
FROM alpine:3.22 AS builder
# TODO: Add croaring-dev once available in Alpine Linux.
# https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/87769
RUN apk add --no-cache \
clang \
cmake \
git \
linux-headers \
make \
python3-dev \
\
bzip2-dev \
catch2-3 \
capnproto-dev \
cxxopts-dev \
expat-dev \
libosmium-dev \
lmdb-dev \
nlohmann-json \
openssl-dev \
protozero-dev \
zlib-dev
WORKDIR /usr/src/osmexpress
COPY . /usr/src/osmexpress
RUN cmake -DCMAKE_BUILD_TYPE=Release .
RUN make -j16 && ./osmxTest && make install
FROM alpine:3.22
# cxxopts, libosmium, nlohmann-json and protozero are header-only
# C++ libraries; catch2 is only used for testing. We do not need
# them in the production container.
RUN apk add --no-cache \
libbz2 \
libcrypto3 \
capnproto \
libexpat \
libssl3 \
lmdb \
zlib
COPY --from=builder /usr/local/bin/osmx /usr/local/bin/osmx
ENTRYPOINT [ "/usr/local/bin/osmx" ]