I'm trying to run offline version of OpenStreetMaps on my server.
I have an ASP.NET MVC app which displays OSM map. So far I run the quick start example from OpenLayers.
var map = new ol.Map({
target: 'map',
layers: [
new ol.layer.Tile({
source: new ol.source.OSM()
})
],
view: new ol.View({
center: ol.proj.fromLonLat([
37.41,
8.82
]),
zoom: 4
})
});
The thing is I need everything offline. I already downloaded planet-latest.osm.bz2 file, but I'm confused what are next steps.
I read I have to render tiles now, from osm file, right? I tried to use Mapnik/Maperetive to achieve this but it didn't go well. I also don't know how to connect all there things together.
@EDIT1 Do I have to render all tiles before use(approx. 20TB) or can I render tiles on demand (when someone will use map)?
I'll just clarify a couple different bits of terminology for you:
The information above may not be necessary for you, because Open Tile Server has some sensible defaults and is probably the best place for you to look: https://opentileserver.org/