Last active
May 28, 2020 08:58
-
-
Save 2803media/30bd8432e0421ea03f2d310a17c78042 to your computer and use it in GitHub Desktop.
openrouteservices docker map isochrone
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"ors": { | |
"info": { | |
"base_url": "https://openrouteservice.org/", | |
"support_mail": "[email protected]", | |
"author_tag": "openrouteservice", | |
"content_licence": "LGPL 3.0" | |
}, | |
"services": { | |
"matrix": { | |
"enabled": true, | |
"maximum_routes": 2500, | |
"maximum_routes_flexible": 25, | |
"maximum_search_radius": 5000, | |
"maximum_visited_nodes": 100000, | |
"allow_resolve_locations": true, | |
"attribution": "openrouteservice.org, OpenStreetMap contributors" | |
}, | |
"isochrones": { | |
"enabled": true, | |
"maximum_range_distance": [ | |
{ "profiles": "any", "value": 50000 }, | |
{ "profiles": "driving-car, driving-hgv", "value": 100000 } | |
], | |
"maximum_range_time": [ | |
{ "profiles": "any", "value": 18000 }, | |
{ "profiles": "driving-car, driving-hgv", "value": 3600 } | |
], | |
"maximum_intervals": 10, | |
"maximum_locations": 2, | |
"allow_compute_area": true | |
}, | |
"routing": { | |
"enabled": true, | |
"mode": "normal", | |
"routing_description": "This is a routing file from openrouteservice", | |
"routing_name": "openrouteservice routing", | |
"sources": ["data/osm_file.pbf"], | |
"init_threads": 2, | |
"attribution": "openrouteservice.org, OpenStreetMap contributors", | |
"elevation_preprocessed": false, | |
"profiles": { | |
"active": [ | |
"car", | |
"bike-regular", | |
"bike-electric", | |
"walking" | |
], | |
"default_params": { | |
"encoder_flags_size": 8, | |
"graphs_root_path": "data/graphs", | |
"elevation_provider": "multi", | |
"elevation_cache_path": "data/elevation_cache", | |
"elevation_cache_clear": false, | |
"instructions": true, | |
"maximum_distance": 100000, | |
"maximum_distance_dynamic_weights": 100000, | |
"maximum_distance_avoid_areas": 100000, | |
"maximum_waypoints": 50, | |
"maximum_snapping_radius": 400, | |
"maximum_avoid_polygon_area": 200000000, | |
"maximum_avoid_polygon_extent": 20000, | |
"maximum_distance_alternative_routes": 100000, | |
"maximum_alternative_routes": 3, | |
"maximum_distance_round_trip_routes": 100000, | |
"preparation": { | |
"min_network_size": 200, | |
"min_one_way_network_size": 200, | |
"methods": { | |
"lm": { | |
"enabled": true, | |
"threads": 1, | |
"weightings": "fastest,shortest", | |
"landmarks": 16 | |
} | |
} | |
}, | |
"execution": { | |
"methods": { | |
"lm": { | |
"disabling_allowed": true, | |
"active_landmarks": 8 | |
} | |
} | |
} | |
}, | |
"profile-car": { | |
"profiles": "driving-car", | |
"parameters": { | |
"encoder_flags_size": 8, | |
"encoder_options": "turn_costs=true|block_fords=false|use_acceleration=false", | |
"maximum_distance": 100000, | |
"elevation": true, | |
"maximum_snapping_radius": 350, | |
"preparation": { | |
"min_network_size": 200, | |
"min_one_way_network_size": 200, | |
"methods": { | |
"ch": { | |
"enabled": true, | |
"threads": 1, | |
"weightings": "fastest" | |
}, | |
"lm": { | |
"enabled": false, | |
"threads": 1, | |
"weightings": "fastest,shortest", | |
"landmarks": 16 | |
}, | |
"core": { | |
"enabled": true, | |
"threads": 1, | |
"weightings": "fastest,shortest", | |
"landmarks": 64, | |
"lmsets": "highways;allow_all" | |
} | |
} | |
}, | |
"execution": { | |
"methods": { | |
"ch": { | |
"disabling_allowed": true | |
}, | |
"lm": { | |
"disabling_allowed": true, | |
"active_landmarks": 6 | |
}, | |
"core": { | |
"disabling_allowed": true, | |
"active_landmarks": 6 | |
} | |
} | |
}, | |
"ext_storages": { | |
"WayCategory": {}, | |
"HeavyVehicle": {}, | |
"WaySurfaceType": {}, | |
"RoadAccessRestrictions": { | |
"use_for_warnings": true | |
} | |
} | |
} | |
}, | |
"profile-bike-regular": { | |
"profiles": "cycling-regular", | |
"parameters": { | |
"encoder_options": "consider_elevation=true|turn_costs=true|block_fords=false", | |
"elevation": true, | |
"ext_storages": { | |
"WayCategory": {}, | |
"WaySurfaceType": {}, | |
"HillIndex": {}, | |
"TrailDifficulty": {} | |
} | |
} | |
}, | |
"profile-bike-electric": { | |
"profiles": "cycling-electric", | |
"parameters": { | |
"encoder_options": "consider_elevation=true|turn_costs=true|block_fords=false", | |
"elevation": true, | |
"ext_storages": { | |
"WayCategory": {}, | |
"WaySurfaceType": {}, | |
"HillIndex": {}, | |
"TrailDifficulty": {} | |
} | |
} | |
}, | |
"profile-walking": { | |
"profiles": "foot-walking", | |
"parameters": { | |
"encoder_options": "block_fords=false", | |
"elevation": true, | |
"ext_storages": { | |
"WayCategory": {}, | |
"WaySurfaceType": {}, | |
"HillIndex": {}, | |
"TrailDifficulty": {} | |
} | |
} | |
} | |
} | |
} | |
}, | |
"logging": { | |
"enabled": true, | |
"level_file": "DEBUG_LOGGING.json", | |
"location": "/var/log/ors", | |
"stdout": true | |
}, | |
"system_message": [ | |
{ | |
"active": false, | |
"text": "This message would be sent with every routing bike fastest request", | |
"condition": { | |
"request_service": "routing", | |
"request_profile": "cycling-regular,cycling-mountain,cycling-road,cycling-electric", | |
"request_preference": "fastest" | |
} | |
}, | |
{ | |
"active": false, | |
"text": "This message would be sent with every request for geojson response", | |
"condition": { | |
"api_format": "geojson" | |
} | |
}, | |
{ | |
"active": false, | |
"text": "This message would be sent with every request on API v1 from January 2020 until June 2050", | |
"condition": { | |
"api_version": 1, | |
"time_after": "2020-01-01T00:00:00Z", | |
"time_before": "2050-06-01T00:00:00Z" | |
} | |
}, | |
{ | |
"active": false, | |
"text": "This message would be sent with every request" | |
} | |
] | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
ors-app: | |
container_name: ors-app | |
ports: | |
- 8080:8080 | |
image: openrouteservice/openrouteservice:v6.1.0 | |
build: | |
context: ../ | |
args: | |
APP_CONFIG: ./docker/conf/app.config.sample | |
OSM_FILE: ./docker/data/france-latest.osm.pbf | |
volumes: | |
- ./graphs:/ors-core/data/graphs | |
- ./elevation_cache:/ors-core/data/elevation_cache | |
- ./logs/ors:/var/log/ors | |
- ./logs/tomcat:/usr/local/tomcat/logs | |
- ./conf:/ors-conf | |
- ./data/france-latest.osm.pbf:/ors-core/data/osm_file.pbf | |
environment: | |
- BUILD_GRAPHS=False # Forces the container to rebuild the graphs, e.g. when PBF is changed in app.config | |
- "JAVA_OPTS=-Djava.awt.headless=true -server -XX:TargetSurvivorRatio=75 -XX:SurvivorRatio=64 -XX:MaxTenuringThreshold=3 -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:ParallelGCThreads=4 -Xms1g -Xmx40g -XX:MaxMetaspaceSize=512m -XX:-UseGCOverheadLimit" | |
- "CATALINA_OPTS=-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9001 -Dcom.sun.management.jmxremote.rmi.port=9001 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=188.165.35.155" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#sur le serveur télécharger le master | |
git clone https://github.com/GIScience/openrouteservice.git | |
#puis | |
root@host6-vm105:/home/openrouteservice/docker/data# wget https://download.geofabrik.de/europe/france-latest.osm.pbf | |
#ensuite config voir les fichiers docker-compose.yml et app.config.sample | |
#penser à mettre au moins 40G de mémoire et de l'espace disque avant | |
#build | |
docker-compose up -d | |
#attendre que les graphs soient générés (plusieures heures) | |
#faire une image du container avec les graphs avec un comit | |
docker commit cd79ddb61304 openrouteservice/openrouteservice:FRmay2020_graph | |
#test de la nouvelle image en local | |
docker run -p 8080:8080 --name ors 2803media/docker_ors-app:FRmay2020_graph | |
#envoyer le comit sur le hub | |
#télécharger l'image avec pull | |
#lancer le container | |
#mettre le container en lancement automatique |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment