Update Dockerfile
Browse files- Dockerfile +15 -15
Dockerfile
CHANGED
@@ -1,26 +1,26 @@
|
|
1 |
-
|
2 |
-
FROM ghcr.io/project-osrm/osrm-backend:latest
|
3 |
|
4 |
-
# Set working directory
|
5 |
WORKDIR /data
|
6 |
|
7 |
-
# Install
|
8 |
RUN apt-get update && apt-get install -y wget
|
9 |
|
10 |
-
#
|
11 |
RUN wget http://download.geofabrik.de/europe/germany/berlin-latest.osm.pbf
|
12 |
|
13 |
-
# Process data
|
14 |
-
|
15 |
-
|
16 |
-
|
|
|
|
|
|
|
|
|
17 |
|
18 |
-
#
|
19 |
-
|
20 |
-
|
21 |
|
22 |
-
# Expose required port
|
23 |
EXPOSE 7860
|
24 |
|
25 |
-
|
26 |
-
CMD ["osrm-routed", "--algorithm", "mld", "--port", "7860", "berlin-latest.osm"]
|
|
|
1 |
+
FROM ghcr.io/project-osrm/osrim-backend:latest
|
|
|
2 |
|
|
|
3 |
WORKDIR /data
|
4 |
|
5 |
+
# Install dependencies
|
6 |
RUN apt-get update && apt-get install -y wget
|
7 |
|
8 |
+
# Get Berlin data
|
9 |
RUN wget http://download.geofabrik.de/europe/germany/berlin-latest.osm.pbf
|
10 |
|
11 |
+
# Process data WITH FULL PERMISSIONS:
|
12 |
+
# 1️⃣ Force liberal UMASK during creation (files=666/dirs=777)
|
13 |
+
# 2️⃣ Explicitly verify key file accessibility
|
14 |
+
RUN umask 000 && \
|
15 |
+
osrim-extract -p /opt/car.lua berlin-latest.osm.pbf && \
|
16 |
+
osrim-partition berlin-latest.osrim && \
|
17 |
+
osrim-customize berlin-latest.osrim && \
|
18 |
+
chmod -R a+rwX /data/*
|
19 |
|
20 |
+
# Final global permission sweep ⚠️ Security tradeoff accepted
|
21 |
+
RUN find /data -type d -exec chmod 777 {} \+ && \
|
22 |
+
find /data -type f -exec chmod 666 {} \+
|
23 |
|
|
|
24 |
EXPOSE 7860
|
25 |
|
26 |
+
CMD ["osrim-routed", "--algorithm", "mld", "--port", "7860", "berlin-latest.osrim"]
|
|