cyclosm: add downloaded shp
This commit is contained in:
parent
c2b79805a0
commit
0bbebc0f4a
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,5 +1,6 @@
|
|||||||
pbf/*.pbf
|
pbf/*.pbf
|
||||||
pbf/*.poly
|
pbf/*.poly
|
||||||
|
pbf/shp/*
|
||||||
tiles/*
|
tiles/*
|
||||||
!tiles/.gitkeep
|
!tiles/.gitkeep
|
||||||
database/*
|
database/*
|
||||||
|
13
README.md
13
README.md
@ -20,6 +20,19 @@ For entering into the container, use the "terminal" argument of the run.sh scrip
|
|||||||
docker-compose run --rm map terminal
|
docker-compose run --rm map terminal
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### Cyclosm data dependencies
|
||||||
|
|
||||||
|
##### Shp
|
||||||
|
|
||||||
|
Download the 2 following zip files, unzip them, and place them in the `pbf/shp` folder. They are mounted as volume in the docker-compose.yml.
|
||||||
|
|
||||||
|
- http://osmdata.openstreetmap.de/download/simplified-land-polygons-complete-3857.zip
|
||||||
|
- http://osmdata.openstreetmap.de/download/land-polygons-split-3857.zip
|
||||||
|
|
||||||
|
Also, rename them as in the zip file, so simplified-land-polygons-complete-3857.shp and land-polygons-split-3857.shp.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### Do an import
|
#### Do an import
|
||||||
|
|
||||||
Download a pbf and a poly file of your choice on https://download.geofabrik.de and put it in the `pbf` folder. Change the lines of the pbf and poly paths in the volumes in the `docker-compose.yml` file
|
Download a pbf and a poly file of your choice on https://download.geofabrik.de and put it in the `pbf` folder. Change the lines of the pbf and poly paths in the volumes in the `docker-compose.yml` file
|
||||||
|
@ -11,6 +11,8 @@ services:
|
|||||||
- ./run.sh:/run.sh # for dev
|
- ./run.sh:/run.sh # for dev
|
||||||
- ./pbf/luxembourg-latest.osm.pbf:/data/region.osm.pbf # change here your pbf
|
- ./pbf/luxembourg-latest.osm.pbf:/data/region.osm.pbf # change here your pbf
|
||||||
- ./pbf/luxembourg.poly:/data/region.poly # and your poly
|
- ./pbf/luxembourg.poly:/data/region.poly # and your poly
|
||||||
|
- ./pbf/shp/:/data/shp/
|
||||||
|
#- ./pbf/simplified-land-polygons-complete-3857.zip:/data/simplified-land-polygons-complete-3857.zip
|
||||||
ports:
|
ports:
|
||||||
- "8080:80"
|
- "8080:80"
|
||||||
command: "run"
|
command: "run"
|
||||||
|
3
run.sh
3
run.sh
@ -131,6 +131,9 @@ if [ "$1" == "run" ]; then
|
|||||||
|
|
||||||
cd /data/style/
|
cd /data/style/
|
||||||
git clone --single-branch --branch v0.6 https://github.com/cyclosm/cyclosm-cartocss-style.git --depth 1
|
git clone --single-branch --branch v0.6 https://github.com/cyclosm/cyclosm-cartocss-style.git --depth 1
|
||||||
|
# change shp paths
|
||||||
|
sed -i "s,file: http://osmdata.openstreetmap.de/download,file: /data/shp,g" ./cyclosm-cartocss-style/project.mml
|
||||||
|
sed -i "s/.zip/.shp/g" ./cyclosm-cartocss-style/project.mml
|
||||||
# carto build
|
# carto build
|
||||||
carto cyclosm-cartocss-style/project.mml > mapnik.xml
|
carto cyclosm-cartocss-style/project.mml > mapnik.xml
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user