/import

Primary LanguageJavaScript

OSM Buildings data import

Finally the OSM import scripts for OSM Buildings.

Current version is working with MySQL only. If you like to use PostGIS, consider contributing some code to this module or use OSM2PGSQL instead.

Requirements

You'll need NodeJS installed and a running MySQL server instance.

Setup

  • Import the sql dump structure.mysql.sql into your database.
  • Run npm install to install required NodeJS modules.
  • Create a config file (copy and adapt config.sample.js) with your database parameters.

Import

  • Download some OSM files, i.e. from Geofabrik or from Metro Extracts. Don't extract the files, it's done for you automatically :-)
  • Run node import.js {YOURFILE}.osm.bz2

Copyright

The BZ2 Extraction code is taken from Apache's BZ2 Toolkit. Respect the according licences.