Sign inSign up

mib200/geoiplite2-maxmind

By mib200

•Updated almost 9 years ago

Maxmind GeoipLite 2 Database API server

Image
1

10K+

mib200/geoiplite2-maxmind repository overview

⁠Maxmind GeoipLite 2 Database API App and Docker container

Express app utilising Maxmind GeoLite2 database. The app updates the database file at 00:00 hrs on every Sunday.

⁠Where is the source code for this?

You can take a look in the code at https://github.com/mib200/express-geoiplite2-maxmind⁠

⁠How to use this image?
$ docker container run -d --name geoip-server mib200/geoiplite2-maxmind
⁠How do I expose a port on my local system?

Adding the following parameters of -p 8000:3000 will enable you to access the API from the URL http://localhost:8000/?ip=A.B.C.D⁠

$ docker container run -d --name geoip-server -p 8000:3000 mib200/geoiplite2-maxmind
⁠How to resolve an IP address [API Endpoint]?

Send a query param of ?ip=A.B.C.D at the end of the hosted URL http://localhost:3000/?ip=A.B.C.D

⁠What is the response that we get?
{
    "ip": "A.B.C.D",
    "continent": "Asia",
    "country_code": "IN",
    "country_name": "India",
    "time_zone": "Asia/Kolkata",
    "latitude": 17.3753,
    "longitude": 78.4744,
    "accuracy_radius": 10,
    "city": "Hyderabad",
    "region_name": "Telangana"
}

⁠Features

  • Downloads the latest DB file automatically from Maxmind website.
  • Auto updates the database file every week.
  • Returns an absolute clean JSON response depending on how many fields are found in Maxmind DB response.

⁠References

⁠License

MIT

Tag summary

Content type

Image

Digest

Size

25.4 MB

Last updated

almost 9 years ago

docker pull mib200/geoiplite2-maxmind