maps/backend/scripts/01_download.sh
2026-03-30 10:27:36 +02:00

17 lines
457 B
Bash
Executable file

#!/bin/bash
# scripts/01_download.sh
REGION="europe/netherlands"
DATA_DIR="/data/osm"
GEOFABRIK_BASE="https://download.geofabrik.de"
mkdir -p "$DATA_DIR"
# Download PBF extract (or update if already present)
wget -N "${GEOFABRIK_BASE}/${REGION}-latest.osm.pbf" \
-O "${DATA_DIR}/region.osm.pbf"
# Download the corresponding state file for future diff updates
wget -N "${GEOFABRIK_BASE}/${REGION}-updates/state.txt" \
-O "${DATA_DIR}/state.txt"