Skip to content
Snippets Groups Projects
Commit c5c45940 authored by Alex Reisner's avatar Alex Reisner
Browse files

Clarify required configuration for :maxmind_local.

parent d0c69d6f
No related branches found
No related tags found
No related merge requests found
...@@ -597,7 +597,9 @@ This lookup provides methods for geocoding IP addresses without making a call to ...@@ -597,7 +597,9 @@ This lookup provides methods for geocoding IP addresses without making a call to
* **Documentation**: http://www.maxmind.com/en/city * **Documentation**: http://www.maxmind.com/en/city
* **Terms of Service**: ? * **Terms of Service**: ?
* **Limitations**: ? * **Limitations**: ?
* **Notes**: There are two supported formats for MaxMind local data: binary file, and CSV file imported into an SQL database. **To use a binary file** you must add the *geoip* (or *jgeoip* for JRuby) gem to your Gemfile or have it installed in your system, and specify the path of the MaxMind database in your configuration. For example: * **Notes**: There are two supported formats for MaxMind local data: binary file, and CSV file imported into an SQL database. **You must download a database from MaxMind and set either the `:file` or `:package` configuration option for local lookups to work.**
**To use a binary file** you must add the *geoip* (or *jgeoip* for JRuby) gem to your Gemfile or have it installed in your system, and specify the path of the MaxMind database in your configuration. For example:
Geocoder.configure(ip_lookup: :maxmind_local, maxmind_local: {file: File.join('folder', 'GeoLiteCity.dat')}) Geocoder.configure(ip_lookup: :maxmind_local, maxmind_local: {file: File.join('folder', 'GeoLiteCity.dat')})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment