Heavily influenced by Mike Migurski's Extractotron
Downloads the latest planet in pbf format. Produces, via osmosis, a number of metro extracts in both pbf and bz2 formats. Produces shape files in both imposm and osm2pgsql formats.
GeoJSON is generated via ogr2ogr and output in CRS:84 (e.g. EPSG:4326) projection.
Imposm shapfiles are generated using default projections. As the code allows for the use of either imposm2 or imposm3, that currently means:
- EPSG:3857 for imposm3
- EPSG:90013 for imposm2
Mapzen is using imposm3 to generate these shapefiles, so the imposm shapefiles found at our metro extracts page are using EPSG:3857.
On AWS, a c3.8xl (60GB RAM and at least 75GB of fast disk), will result in the entire process taking ~15 hours.
If you'd rather not go that route, you're in luck. We'll be producing extracts weekly, and you can find them here: Mapzen Metro Extracts
Extract creation is driven off the cities.json file found here: metroextractor-cities. If you'd like to add an extract, you can either update the file directly if you feel comfortable doing so and submit a pull request, or open a GitHub issue and we'll look into doing it for you.
If you'd like to update any other code, please fork, update, write specs for your changes and submit a pull.
include_recipe 'metroextractor'
Tested and supported on the following platforms:
- Ubuntu 12.04LTS
- Ubuntu 14.04LTS
- Chef >= 11.4
apt, ark, osm2pgsql, osmosis postgresql, python, user
vagrant plugin install vagrant-berkshelf
bundle install
berks install
vagrant up
vagrant ssh
- running a planet download and then processing extracts on your local machine might be hit or miss (likely miss)
- well then sir, provision an Ubuntu12.04 LTS system with the provider of your choice, and then bootstrap with chef-solo:
knife solo bootstrap root@${host} -r 'recipe[metroextractor]'
- and re-cook with the following:
knife solo cook root@${host} -r 'recipe[metroextractor]'
- alternatively, you can add the metroextractor cookbook to your chef server and wrap it as you see fit
License: GPL Authors: grant@mapzen.com