A simple Sinatra-based geoip server. It uses the free Maxmind geolite city database with the geoip ruby gem. The database is updated about once a month. The service runs here:
The app is hosted on Heroku and run using Phusion Passenger.
git remote add heroku [email protected]:perkhub-geoip.git git push heroku master
rake geoip:update
Commit and push to Heroku.
Set a username and password with the environment variables AUTH_USERNAME and AUTH_PASSWORD.
Part of the code was copied and distilled from https://github.com/JackDanger/geoip_server