chris 21ebb9667b Add 'estore/' from commit 'e34dfc397c94025670baa2b73b482c01f3033a6a'
git-subtree-dir: estore
git-subtree-mainline: 746868d720b9be1003a2f783b7a12d526d8eea60
git-subtree-split: e34dfc397c94025670baa2b73b482c01f3033a6a
2026-04-13 19:22:23 -04:00

21 lines
607 B
Bash
Executable File

#!/bin/bash
# Downloads and reprocesses Connecticut OSM data, then restarts OSRM.
# Run quarterly or whenever needed.
# Crontab: 0 3 1 1,4,7,10 * /path/to/docker/osrm/update.sh >> /var/log/osrm-update.log 2>&1
set -e
cd "$(dirname "$0")"
mkdir -p data
echo "[$(date)] Downloading Connecticut OSM data..."
curl -L -o data/connecticut-latest.osm.pbf \
https://download.geofabrik.de/north-america/us/connecticut-latest.osm.pbf
echo "[$(date)] Processing..."
docker compose --profile init up --force-recreate osrm-init
echo "[$(date)] Restarting OSRM..."
docker compose up -d osrm
echo "[$(date)] Done."