forked from J-Chaniotis/external-ip
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdefaults.js
62 lines (55 loc) · 1.23 KB
/
defaults.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
module.exports = {
/**
* 'sequential' or 'parallel' ip fetching
* @type {string}
*/
mode: "sequential",
/**
* true: replaces the default services
* false: extends them
* @type {boolean}
*/
replace: false,
/**
* array of urls that return the ip in the document body
* @type {Array}
*/
services: [
"http://icanhazip.com/",
"http://ifconfig.io/ip",
"http://ip.appspot.com/",
"http://ident.me/",
"http://whatismyip.akamai.com/",
"http://tnx.nl/ip",
"http://myip.dnsomatic.com/",
"http://ipecho.net/plain",
"http://diagnostic.opendns.com/myip",
"http://api.ipify.org/",
"http://trackip.net/ip"
],
/**
* timeout per request
* @type {number}
*/
timeout: 1000,
/**
* http(s).Agent instance to use
* @type {http.Agent|https.Agent}
*/
agent: null,
/**
* user agent used for ip requests
* @type {string}
*/
userAgent: "curl/",
/**
* follow htt 3xx responses as redirects
* @type {boolean}
*/
followRedirect: true,
/**
* maximum redirect count
* @type {number}
*/
maxRedirects: 10
};