Geolix Adapter: MMDB2 v0.1.0 Geolix.Adapter.MMDB2 View Source

Adapter for Geolix to work with MMDB2 databases.

Adapter Configuration

To start using the adapter with a compatible database you need to add the required configuration entry to your :geolix configuration:

config :geolix,
  databases: [
    %{
      id: :my_mmdb_database,
      adapter: Geolix.Adapter.MMDB2,
      source: "/absolute/path/to/my/database.mmdb"
    }
  ]

Database Configuration

In order to work this adapter requires a :source configuration value to point to a valid MMDB2 format database.

Compressed Databases

Some limited support is built in to allow working with compressed databases if the filename matches one of the following patterns:

  • *.gz - It is expected to be a gzip compressed file
  • *.tar - It is expected to be a tarball and the first file in the archive ending in .mmdb will be loaded.
  • *.tar.gz - Combination of the above