Skip to content

Create a Geonames gazetteer index in Elasticsearch

License

Notifications You must be signed in to change notification settings

vks/es-geonames

 
 

Repository files navigation

ES-Geonames

Create a Geonames index running locally in Elasticsearch container. The index is stored in a data volume, which can be moved elsewhere and quickly stood up.

To download the Geonames.org gazetter, set up Dockerized Elasticsearch, and load the gazetteer into Elasticsearch, clone this repository and run

bash create_index.sh

The geonames_index/ directory can be compressed and moved elsewhere. To start a new Elasticsearch instance using the prepared index, run

sudo docker run -d -p 127.0.0.1:9200:9200 -v /PATH/TO/geoname_index/data/:/usr/share/elasticsearch/data elasticsearch:5.1.2

where /PATH/TO/geonames_index/data/ is the full path to the decompressed index on your host machine.

This Geonames index is meant to be used with OEDA's full text geoparse, Mordecai.

ES-Geonames with Logstash

The same work for the python script but with posibilities to create the index based in the pipeline defined by the developer in the file logstash/logstash-pipeline.conf. See logstash folder.

About

Create a Geonames gazetteer index in Elasticsearch

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 79.6%
  • Shell 20.4%