Update README with links to tileserver-gl-data

This commit is contained in:
Petr Sloup 2016-05-03 15:49:39 +02:00
parent 2a55517a2d
commit d3a9b6cfbf

View file

@ -12,75 +12,21 @@
- `node src/main.js`
## Sample data
Sample data can be downloaded at https://github.com/klokantech/tileserver-gl/releases/download/v0.0.2/test_data.zip
Sample data can be downloaded at https://github.com/klokantech/tileserver-gl-data/archive/master.zip
#### Usage
- unpack somewhere and `cd` to the directory
- `docker run -it -v $(pwd):/data -p 8080:80 klokantech/tileserver-gl`
- (or `node path/to/repo/src/main.js`)
#### Data
- tiles from http://osm2vectortiles.org/
- styles modified from https://github.com/klokantech/osm2vectortiles-gl-styles
## Configuration
Create `config.json` file in the root directory.
The config file can contain definition of several paths where the tiles will be served.
### Example configuration file
See https://github.com/klokantech/tileserver-gl-data/blob/master/config.json
```json
{
"options": {
"paths": {
"root": "",
"fonts": "glyphs",
"sprites": "sprites",
"styles": "styles",
"mbtiles": ""
},
"domains": [
"localhost:8080",
"127.0.0.1:8080"
],
"formatEncoding": {
"png": 6,
"jpeg": 80,
"webp": 90
}
},
"styles": {
"test": {
"style": "basic-v8.json",
"tilejson": {
"type": "overlay",
"bounds": [8.44806, 47.32023, 8.62537, 47.43468]
}
},
"hybrid": {
"style": "satellite-hybrid-v8.json",
"serve_rendered": false,
"tilejson": {
"format": "webp",
"center": [8.536715, 47.377455, 6]
}
},
"streets": {
"style": "streets-v8.json",
"serve_data": false,
"tilejson": {
"center": [8.536715, 47.377455, 6]
}
}
},
"data": {
"zurich-vector": {
"mbtiles": "zurich.mbtiles"
}
}
}
```
**Note**: To specify local mbtiles as source of the vector tiles inside the style, use urls with `mbtiles` protocol with path relative to the `cwd + options.paths.root + options.paths.mbtiles`. (For example `mbtiles://switzerland.mbtiles`)
## Available URLs