New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

maxmind-loader

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

maxmind-loader

Get maxmind paid and lite geoip data updates

latest
Source
npmnpm
Version
0.5.12
Version published
Weekly downloads
5
150%
Maintainers
1
Weekly downloads
 
Created
Source

maxmind-loader NPM version Build Status Dependency Status License

Get maxmind paid and lite geoip data updates

Install :hammer:

npm install maxmind-loader

Usage :wrench:

var maxloader = require('maxmind-loader');

maxloader(callback);

// default values shown
maxloader({
	license: undefined, // maxmind license string for paid data otherwise free version loaded
	day:     'tuesday', // day of the week to load for paid subscription
	edition: 132,       // paid subscription edition
	extract: true,      // extract compressed files
	dest:    '/tmp/'    // should load /tmp/GeoCityLite.dat, async operation
}, function (err, filepath) {
	if (err) {
		console.log(err);
	} else {
		console.log(filepath, 'loaded');
	}
});

Free Geo Data Example :wrench:

var maxmind   = require('maxmind')
  , maxloader = require('maxmind-loader');

maxloader(function(error, filepath) {
	maxmind.init(filepath); // intialize with /tmp/GeoLiteCity.dat
});

Paid Geo Data Example :wrench:

var options = { license: 'MAXMIND_LICENSE' };

maxloader(options, function(err, filepath) {
	if (err) {
		console.log(err);
	} else {
		maxmind.init(filepath, { memoryCache: true });
	}
})

License: MIT :unlock:

Dependencies:

compress-buffer date-utils tar wgetjs

Development Dependencies:

grunt grunt-bump grunt-license license-md mocha should

Keywords

maxmind

FAQs

Package last updated on 16 Sep 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts