MaxMind GeoIP
The maxmind-geoip analysis controller performs IP-to-location lookups to identify geographic information.
Note
You need MaxMind databases to run this controller.
Configuration
yaml
analysisControllers:
- name: geoip
type: maxmind-geoip
settings:
databasePath: config/GeoLite2-City.mmdb1
2
3
4
5
2
3
4
5
Upstream Headers Injected
X-GeoIP-City— City nameX-GeoIP-PostalCode— Postal/ZIP codeX-GeoIP-Region— State/province nameX-GeoIP-Country— Country nameX-GeoIP-CountryISO— ISO country code (e.g.,US)X-GeoIP-Continent— Continent nameX-GeoIP-TimeZone— IANA timezoneX-GeoIP-Latitude— Decimal latitudeX-GeoIP-Longitude— Decimal longitude
Caching & Errors
- In-memory cache prevents repeated database hits; cache hits are logged at debug level.
- If the IP is not present in the database or a read error occurs, the controller logs a warning and returns a report with a
nillookup result (headers are omitted).
Use Cases
- Geographic access restrictions
- Content localization
- Analytics and reporting
- Compliance requirements (e.g., GDPR, data residency)
Requirements
- MaxMind GeoLite2 City Database
- Weekly database updates recommended