An open API service indexing awesome lists of open source software.

https://github.com/lab5e/gotileserver

OSM/OpenMapTile server
https://github.com/lab5e/gotileserver

Last synced: about 1 year ago
JSON representation

OSM/OpenMapTile server

Awesome Lists containing this project

README

          

# OpenMapTile server library

This uses data from [OpenStreetMap](https://www.openstreetmap.org/#map=17/63.43213/10.40691). The OSM data
has usually been converted from PostgreSQL GIS data into bitmap tiles but this is an slightly outdated
technique and [OpenMapTiles](https://openmaptiles.org) is a vector-based solution built on top of OSM data.

The styling is... interesting... There's a lot of hard coded references to external resources so the styles
included in this project has been massaged to point to both the proper tile data and local resources.

## Using custom tilers

The library includes a sample set of tiles from a different library. To add your own tiles follow the guidelines below.

## Building the tiles

The tiles can be rebuilt in a few minutes (a more elaborate description is at https://blog.kleunen.nl/blog/tilemaker-generate-map).

Tools needed:

* Osmium - install with `brew install osmium-tool` on macOS
* [Tilemaker](https://tilemaker.org) - build from the [GitHub sources](https://github.com/systemed/tilemaker)
* wget - pull a suitable data set from [GeoFabrik](http://download.geofabrik.de)

Run the following commands to extract the data into tiles

```shell
wget http://download.geofabrik.de/europe/norway-latest.osm.pbf
osmium extract --bbox=9.78,63.17,10.97,63.56 --set-bounds --strategy=smart norway-latest.osm.pbf --output trondheim.osm.pbf
tilemaker --input trondheim.osm.pbf --output tiles --process [...]/resources/process-openmaptiles.lua \
--config [...]/resources/config-openmaptiles.json
```

The whole process should take three to four minutes on a decent computer.