kopia lustrzana https://github.com/osm2vectortiles/osm2vectortiles
Reworked import and export process
rodzic
8a20dee717
commit
c4c0e23a9b
|
|
@ -1,73 +0,0 @@
|
|||
---
|
||||
layout: page
|
||||
title: FAQ
|
||||
published: true
|
||||
---
|
||||
|
||||
# Import and Export Process
|
||||
|
||||
### Import
|
||||
|
||||
Import toolchain based on [Imposm 3](https://github.com/omniscale/imposm3) to
|
||||
import [OpenStreetMap data](http://wiki.openstreetmap.org/wiki/Downloading_data)
|
||||
into a [PostGIS](http://postgis.net/) database.
|
||||
The mapping is optimized for fast generation of vectortiles.
|
||||
|
||||

|
||||
|
||||
### Export
|
||||
|
||||
Export toolchain consisting of [our custom tm2source project](https://github.com/geometalab/open-streets.tm2source)
|
||||
based on the import mapping and tools to scale exporting of the vectortiles horizontally.
|
||||
|
||||

|
||||
|
||||
### Serve
|
||||
|
||||
A very easy tileserver where you can simply drop in your `tm2` style project and our produced `mbtiles` file
|
||||
and it will serve a custom styled OSM map.
|
||||
|
||||

|
||||
|
||||
## Development
|
||||
|
||||
We use Docker extensively for development and deployment.
|
||||
The easiest way to get started is using [Docker Compose](https://www.docker.com/docker-compose).
|
||||
|
||||
Start up your PostGIS container with the data container attached.
|
||||
|
||||
```
|
||||
docker-compose up -d postgis
|
||||
```
|
||||
|
||||
In order to render the oceans you need to import the water polygons
|
||||
from [OpenStreetMapData.com](http://openstreetmapdata.com/data/water-polygons).
|
||||
Run the `import-water` container.
|
||||
|
||||
```
|
||||
docker-compose up import-water
|
||||
```
|
||||
|
||||
Download a PBF and put it into the local `import` directory.
|
||||
|
||||
```
|
||||
wget https://s3.amazonaws.com/metro-extracts.mapzen.com/zurich_switzerland.osm.pbf
|
||||
```
|
||||
|
||||
Now you need to import the PBF files into PostGIS.
|
||||
|
||||
```
|
||||
docker-compose up import
|
||||
```
|
||||
|
||||
Export the data as MBTiles file to the `export` directory.
|
||||
|
||||
```
|
||||
docker-compose up export
|
||||
```
|
||||
|
||||
Serve the tiles as raster tiles from `export` directory.
|
||||
|
||||
```
|
||||
docker-compose up serve
|
||||
```
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
---
|
||||
layout: page
|
||||
title: Import and Export Process
|
||||
published: true
|
||||
---
|
||||
|
||||
# Import and Export Process
|
||||
|
||||
### Import
|
||||
|
||||
In the import process all [data sources](/docs/data-sources.html) get imported into a single PostGIS database. The figure below shows which data source gets imported with which import tool.
|
||||
|
||||

|
||||
|
||||
The import sql container adds helper sql functions, which are used inside the [data style](https://github.com/osm2vectortiles/osm2vectortiles/blob/master/open-streets.tm2source/data.yml).
|
||||
|
||||
### Export
|
||||
|
||||
For generating the vector tiles the tilelive tool [tl](https://github.com/mojodna/tl) is used which wraps around Mapnik. The data style defines all feature sets (layers) and is transformed into a Mapnik XMLstylesheet by the tilelive-tm2source provider. Tilelive-bridge calls Mapnik with the generated stylesheet and hands the generated data over to node-mbtiles, which stores the vector tiles in a MBTiles container.
|
||||
|
||||

|
||||
|
|
@ -33,8 +33,7 @@ who want to reuse part of our process or want to contribute.
|
|||
- [How to create your own extract?](/docs/extracts.html)
|
||||
- How to add my own data to the vector tiles? (Overlay, its just a base map / Import to PostGIS)
|
||||
|
||||
- [Import and Export Process](/docs/docker-based-process.html)
|
||||
- [Import OSM data into PostGIS](/docs/import.html)
|
||||
- [Import and Export Process](/docs/import-export-process.html)
|
||||
- [Imposm Mapping Schema](/docs/imposm-schema.html)
|
||||
- [Develop with Mapbox Studio in Docker](/docs/mapbox-studio-in-docker.html)
|
||||
- [Compare visual with Mapbox Streets](/docs/compare-visual.html)
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ Clone the osm2vectortiles project.
|
|||
|
||||
```
|
||||
git clone https://github.com/osm2vectortiles/osm2vectortiles.git
|
||||
cd osm2vectortiles
|
||||
```
|
||||
|
||||
Start up your PostGIS container with the data container attached.
|
||||
|
|
|
|||
Plik binarny nie jest wyświetlany.
|
Po Szerokość: | Wysokość: | Rozmiar: 18 KiB |
Plik binarny nie jest wyświetlany.
|
Po Szerokość: | Wysokość: | Rozmiar: 34 KiB |
Ładowanie…
Reference in New Issue