Skip to content

Commit 951cc9a

Browse files
committed
feat(osrm): upgrade to 6.0.0. feat(valhalla): 3.6.1
1 parent c84f1a2 commit 951cc9a

File tree

2 files changed

+39
-59
lines changed

2 files changed

+39
-59
lines changed

changelog.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# CHANGELOG
22

3+
## 4.0.0
4+
UPDATED :
5+
- (breaking) upgrade OSRM to 6.0.0
6+
- upgrade Valhalla to 3.6.1, using main repo instead of custom one
7+
- lighter and faster docker image build
8+
39
## 3.1.5
410
FIXED :
511
- database manager does not raie error when retries have failed
@@ -18,7 +24,7 @@ CHANGED:
1824

1925
## 3.1.0
2026
ADDED:
21-
- fields vla_par_defaut, cout_penalites, vehicule_leger_interdit, cout_vehicule_prioritaire
27+
- fields vla_par_defaut, cout_penalites, vehicule_leger_interdit, cout_vehicule_prioritaire
2228

2329
## 3.0.0
2430
REMOVED:

docker/debian/Dockerfile

Lines changed: 32 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,41 @@
1-
FROM python:3.10.9-slim-bullseye as build
2-
3-
### Installation des dépendances
4-
RUN apt update && apt install -y wget git g++ cmake libboost-dev libboost-filesystem-dev libboost-thread-dev \
5-
libboost-system-dev libboost-regex-dev libxml2-dev libsparsehash-dev libbz2-dev \
6-
zlib1g-dev libzip-dev libgomp1 liblua5.3-dev \
7-
pkg-config libgdal-dev libboost-program-options-dev libboost-iostreams-dev \
8-
libboost-test-dev libtbb-dev libexpat1-dev
9-
10-
### Installation d'OSRM
11-
WORKDIR /home/osrm/
12-
RUN wget https://github.com/Project-OSRM/osrm-backend/archive/v5.26.0.tar.gz && tar -xzf v5.26.0.tar.gz && cd osrm-backend-5.26.0 && \
13-
mkdir -p build && cd build && cmake .. -DCMAKE_BUILD_TYPE=Release && cmake --build . && cmake --build . --target package
14-
15-
### Installation de Valhalla
16-
### Dépendances
17-
RUN apt-get update && \
18-
apt-get install -y cmake make libtool pkg-config g++ gcc curl unzip jq lcov protobuf-compiler \
19-
vim-common locales libcurl4-openssl-dev zlib1g-dev liblz4-dev libprotobuf-dev && \
20-
apt-get install -y libgeos-dev libgeos++-dev libluajit-5.1-dev libspatialite-dev libsqlite3-dev wget sqlite3 spatialite-bin python3-shapely && \
21-
apt-get install -y libsqlite3-mod-spatialite
22-
23-
WORKDIR /home/prime-server
24-
RUN apt-get install -y git cmake autoconf automake pkg-config libtool make gcc g++ lcov libcurl4-openssl-dev libzmq3-dev libczmq-dev
25-
RUN git clone --depth 1 --recursive https://github.com/kevinkreiser/prime_server.git && cd prime_server && \
26-
cmake -B build . && cmake --build build && make -C build install
27-
28-
WORKDIR /home/valhalla/
29-
RUN pip install --upgrade "conan<2.0.0"
30-
RUN git clone --branch 3.2.0-with_hard_exclude --depth 1 --recursive https://github.com/IGNF/valhalla.git && cd valhalla && \
31-
mkdir build && cmake -B build -DCMAKE_BUILD_TYPE=Release && make -C build && make -C build package
32-
33-
FROM python:3.10.9-slim-bullseye as r2gg
34-
35-
ENV PYTHON_VERSION "3.10.9"
1+
# OSRM binaries
2+
FROM ghcr.io/project-osrm/osrm-backend:v6.0.0 AS osrm
3+
4+
# Valhalla binaries
5+
FROM ghcr.io/valhalla/valhalla:3.6.1 AS valhalla
6+
7+
# Prime server build
8+
FROM debian:bookworm AS prime_build
9+
RUN apt-get update && apt-get install -y \
10+
git cmake make gcc g++ pkg-config \
11+
libcurl4-openssl-dev libzmq3-dev libczmq-dev
12+
13+
RUN git clone --depth 1 --recursive https://github.com/kevinkreiser/prime_server.git
14+
WORKDIR /prime_server
15+
RUN cmake -B build . && cmake --build build && make -C build install
16+
17+
# Final runtime image
18+
FROM python:3.10.19-slim-trixie AS r2gg
19+
20+
ENV PYTHON_VERSION="3.10.9"
3621
ENV HOME=/home
3722

38-
### Installation des dépendances pour OSRM
39-
RUN apt update && apt install -y libboost-dev libboost-filesystem-dev libboost-thread-dev \
40-
libboost-system-dev libboost-regex-dev libxml2-dev libsparsehash-dev \
41-
libgomp1 liblua5.3-dev \
42-
pkg-config libgdal-dev libboost-program-options-dev libboost-iostreams-dev \
43-
libboost-test-dev libtbb-dev libexpat1-dev
44-
45-
### Installation des dépendances pour Valhalla
46-
RUN apt-get update && \
47-
apt-get install -y libtool pkg-config curl unzip jq lcov protobuf-compiler \
48-
vim-common locales libcurl4-openssl-dev zlib1g-dev liblz4-dev libprotobuf-dev && \
49-
apt-get install -y libgeos-dev libgeos++-dev libluajit-5.1-dev libspatialite-dev libsqlite3-dev wget sqlite3 spatialite-bin python3-shapely && \
50-
apt-get install -y libsqlite3-mod-spatialite
51-
RUN apt-get install -y git libcurl4-openssl-dev libzmq3-dev libczmq-dev
52-
53-
### Installation d'OSRM
54-
COPY --from=build /home/osrm/osrm-backend-5.26.0/build/OSRM-0.1.1-Linux.tar.gz ./
55-
RUN tar -xzvf OSRM-0.1.1-Linux.tar.gz && cd OSRM-0.1.1-Linux && cp -r bin/* /usr/bin/ && cp -r lib/* /usr/lib/ && cp -r include/* /usr/include/ && cp -r share/* /usr/share/
23+
# Runtime dependencies only
24+
RUN apt-get update && apt-get install -y \
25+
libboost-filesystem-dev libboost-system-dev \
26+
libcurl4 libprotobuf-dev libgeos-dev \
27+
libluajit-5.1-2 libsqlite3-mod-spatialite \
28+
&& rm -rf /var/lib/apt/lists/*
29+
30+
COPY --from=osrm /usr/local/bin/osrm-* /usr/local/bin/
31+
COPY --from=osrm /usr/local/lib /usr/local/lib
5632

5733
### Installation prime-server
58-
COPY --from=build /usr/local/lib/libprime_server.so.0.7.2 /usr/lib/libprime_server.so.0.0.0
59-
COPY --from=build /usr/local/lib/libprime_server.so.0 /usr/lib/libprime_server.so.0
60-
COPY --from=build /usr/local/lib/libprime_server.so /usr/lib/libprime_server.so
34+
COPY --from=prime_build /usr/local/lib/libprime_server.so* /usr/lib/
6135

6236
### Installation de valhalla
63-
COPY --from=build /home/valhalla/valhalla/build/valhalla-3.2.0-Linux.tar.gz ./
64-
RUN tar -xzvf valhalla-3.2.0-Linux.tar.gz && cd valhalla-3.2.0-Linux && cp -r bin/* /usr/bin/ && cp -r lib/* /usr/lib/ && cp -r include/* /usr/include/ && cp -r share/* /usr/share/
37+
COPY --from=valhalla /usr/local/bin/valhalla_* /usr/local/bin/
38+
COPY --from=valhalla /usr/local/lib/libvalhalla* /usr/local/lib/
6539

6640
### Installation des dépendances pour psycopg2
6741
RUN apt update && \

0 commit comments

Comments
 (0)