@andrew great stuff I’ve actually been searching for a post like this recently and that’s awesome.
If you ever want to go to next level- there are some use cases where people want to route or geocode without sending the data to another service (eg you have confidential data and cannot share it). I’d love to see someone show how to do these things locally. I saw there is an R package called dodgr that should be able to do this with osm data but haven’t seen it being implemented.
@andrew Brilliant, I think you are right, I am going to dig deeper into this. Thanks!
@mpanhans And it looks like Nominatim (for geocoding locations) can also run from Docker or locally https://nominatim.org/release-docs/latest/admin/Installation/, so it should theoretically be possible to have non-remote instances of Nominatim and OSRM for locations and routing
@mpanhans I *think* you can run a whole local instance of OSRM that doesn't phone out anywhere (like through docker https://github.com/Project-OSRM/osrm-backend#using-docker or just on a linux server), and it looks like you have to supply it the raw OSM files and it handles all the routing locally. There's an argument to osrm::osrmRoute() that lets you specify the server, so I think you could just point it to localhost:5000 or wherever and it would work the same way