osrm-backend/docker-orchestration/osrm-frontend-docker/osrm_options.js
CoderBear801 5fcfab1046 feat: Add docker image for OSRM frontend
- docker image contains OSRM frontend and nginx
2019-06-14 17:14:53 -07:00

53 lines
2.3 KiB
JavaScript
Executable File

'use strict';
var streets = L.tileLayer('https://api.tiles.mapbox.com/v4/mapbox.streets/{z}/{x}/{y}@2x.png?access_token=pk.eyJ1IjoibXNsZWUiLCJhIjoiclpiTWV5SSJ9.P_h8r37vD8jpIH1A6i1VRg', {
attribution: '<a href="https://www.mapbox.com/about/maps">© Mapbox</a> <a href="http://openstreetmap.org/copyright">© OpenStreetMap</a> | <a href="http://mapbox.com/map-feedback/">Improve this map</a>'
}),
outdoors = L.tileLayer('https://api.tiles.mapbox.com/v4/mapbox.outdoors/{z}/{x}/{y}@2x.png?access_token=pk.eyJ1IjoibXNsZWUiLCJhIjoiclpiTWV5SSJ9.P_h8r37vD8jpIH1A6i1VRg', {
attribution: '<a href="https://www.mapbox.com/about/maps">© Mapbox</a> <a href="http://openstreetmap.org/copyright">© OpenStreetMap</a> | <a href="http://mapbox.com/map-feedback/">Improve this map</a>'
}),
satellite = L.tileLayer('https://api.tiles.mapbox.com/v4/mapbox.streets-satellite/{z}/{x}/{y}@2x.png?access_token=pk.eyJ1IjoibXNsZWUiLCJhIjoiclpiTWV5SSJ9.P_h8r37vD8jpIH1A6i1VRg', {
attribution: '<a href="https://www.mapbox.com/about/maps">© Mapbox</a> <a href="http://openstreetmap.org/copyright">© OpenStreetMap</a> | <a href="http://mapbox.com/map-feedback/">Improve this map</a>'
}),
osm = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
attribution: '© <a href="http://www.openstreetmap.org/copyright/en">OpenStreetMap</a> contributors'
}),
osm_de = L.tileLayer('http://{s}.tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png', {
attribution: '© <a href="http://www.openstreetmap.org/copyright/en">OpenStreetMap</a> contributors'
}),
small_components = L.tileLayer('http://tools.geofabrik.de/osmi/tiles/routing_i/{z}/{x}/{y}.png', {})
module.exports = {
defaultState: {
centerLat: 37.399016,
centerLng: -121.976676,
center: L.latLng(37.399016, -121.976676),
zoom: 13,
waypoints: [],
language: 'en',
alternative: true,
layer: streets
},
services: [{
label: 'Car (fastest)',
path: '/api/route/v1/'
}],
layer: [{
'Mapbox Streets': streets,
'Mapbox Outdoors': outdoors,
'Mapbox Streets Satellite': satellite,
'openstreetmap.org': osm,
'openstreetmap.de.org': osm_de
}],
overlay: {
'Small Components': small_components
},
baselayer: {
one: streets,
two: outdoors,
three: satellite,
four: osm,
five: osm_de
}
};