Geonames Search is a full-text search service for Geonames content, designed to facilitate the querying of geographical data through a simple and efficient interface. Built using Python, Flask, and Opensearch, this service provides a robust backend infrastructure leveraging Opensearch for data storage and full-text search capabilities, along with Redis for caching.
Note: This is a hobby project.
/geonames?q=<query>.These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
1. Clone the repository
git clone https://github.com/m3nin0-labs/geonames-search.git
cd geonames-search2. Start the Infrastructure
Use the make up command to start the OpenSearch instance, Redis cache, and the Geonames Search service.
make up3. Index Geonames
To index the Geonames data, you can use the Geonames Index project.
1. Clone the repository
git clone https://github.com/m3nin0-labs/geonames-search.git
cd geonames-search2. Install Dependencies
Install all necessary Python dependencies using Poetry.
poetry install --with dev3. Run the Application
Start the Flask application.
FLASK_APP=geonames_api/main.py flask runNow, you are ready to develop!
To use the Geonames Search service, simply send a GET request to the endpoint with your search query:
GET /geonames?q=LondonResponses will include matched geographical data from the Geonames database.
We welcome contributions! If you have suggestions for improvements or bug fixes, please feel free to fork the repository and submit a pull request.
geonames-search is distributed under the MIT license. See LICENSE for more details.