Sign inSign up

strikehawk/tileserver-gl

By strikehawk

•Updated over 5 years ago

A fork from https://github.com/maptiler/tileserver-gl, with new features and improvements

Image
0

2.1K

strikehawk/tileserver-gl repository overview

tileserver-gl

⁠TileServer GL

Build Status Docker Hub

Vector and raster maps with GL styles. Server side rendering by Mapbox GL Native. Map tile server for Mapbox GL JS, Android, iOS, Leaflet, OpenLayers, GIS via WMTS, etc.

⁠Get Started

Make sure you have Node.js version 10 installed (running node -v it should output something like v10.17.0).

Install tileserver-gl with server-side raster rendering of vector tiles with npm

npm install -g tileserver-gl

Now download vector tiles from OpenMapTiles⁠.

curl -o zurich_switzerland.mbtiles https://[GET-YOUR-LINK]/extracts/zurich_switzerland.mbtiles

Start tileserver-gl with the downloaded vector tiles.

tileserver-gl zurich_switzerland.mbtiles

Alternatively, you can use the tileserver-gl-light package instead, which is pure javascript (does not have any native dependencies) and can run anywhere, but does not contain rasterization on the server side made with MapBox GL Native.

⁠Using Docker

An alternative to npm to start the packed software easier is to install Docker⁠ on your computer and then run in the directory with the downloaded MBTiles the command:

docker run --rm -it -v $(pwd):/data -p 8080:80 maptiler/tileserver-gl

This will download and start a ready to use container on your computer and the maps are going to be available in webbrowser on localhost:8080.

On laptop you can use Docker Kitematic⁠ and search "tileserver-gl" and run it, then drop in the 'data' folder the MBTiles.

⁠Running on local Linux instance

Start by installing all dependency packages

sudo apt-get -y install \
    apt-transport-https \
    curl \
    unzip \
    build-essential \
    python \
    libcairo2-dev \
    libgles2-mesa-dev \
    libgbm-dev \
    libllvm3.9 \
    libprotobuf-dev \
    libxxf86vm-dev \
    xvfb \
    x11-utils \
    nodejs \
    npm

Once this is node, install Node.js and NPM

sudo npm i --unsafe-perm=true --allow-root

To run the application

⁠Documentation

You can read full documentation of this project at https://tileserver.readthedocs.io/⁠.

Tag summary

Content type

Image

Digest

Size

164.3 MB

Last updated

over 5 years ago

docker pull strikehawk/tileserver-gl