This repo combining osrm-backend APIs with nginx based on docker
- docker
- docker-build
- docker-compose
- jq
To deploy this project first download map file for example
./run.sh download -g "http://download.geofabrik.de/asia/iran-latest.osm.pbf"
after downloading map file run
./run.sh setup
for getting duration(secon) and distance(metre) between two points run
./run.sh get -s 51.42838,35.80697 -d 51.42088,35.68590
option "-s" is first point and "-d" means second point with format "<Longitude>,<Latitude>"
Usage:
run.sh setup -m <MAP> # setup project
run.sh start #start containers
run.sh stop #stop containers
run.sh destroy #stop and delete all containers
run.sh download -g <URL> #download MAP file
run.sh list #list all map files
run.sh status #get status of containers
run.sh get -s <FIRST_Longitude,FIRST_Latitude> -d <SECOND_Longitude,SECOND_Latitude> #get distance and duration between two point based on mode