-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.env.example
55 lines (51 loc) · 1.99 KB
/
.env.example
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
; This is an example env file for the IP Analyzer service.
; Service configuration
[config]
ANALYZER_PROTO = "tcp" ; tcp or ssl
ANALYZER_ADDR = "127.0.0.1" ; use 0.0.0.0 if you are using docker
ANALYZER_PORT = 3000
ANALYZER_SSL_CERT = "" ; SSL signed certificate
ANALYZER_SSL_KEY = "" ; SSL private key
ANALYZER_WORKERS = 1
ANALYZER_MAX_MEMORY = 64 ; in MB
ANALYZER_MAX_REQUEST = -1 ; auto restart service after max request, -1 to disable
ANALYZER_RESTART_CRON = "" ; auto restart with Cron pattern, empty to disable
ANALYZER_LOG = true
ANALYZER_LOG_LEVEL = "notice" ; "debug", "info", "notice", "warning" or "error"
ANALYZER_LOG_OUTPUT = "error_log" ; "error_log" or "syslog"
; Service authentication
[auth]
ANALYZER_AUTH = false
ANALYZER_AUTH_HASH_METHOD = "sodium" ; "bcrypt", "argon2i" or "sodium"
ANALYZER_AUTH_HASH = ""
; Redis settings
[redis]
REDIS_ENABLE = false
REDIS_PROTO = "tcp" ; tcp or tls
REDIS_ADDR = "127.0.0.1" ; use 0.0.0.0 if you are using docker
REDIS_PORT = 6379
REDIS_KEY_PREFIX = "IP_ANALYZER:"
REDIS_TIMEOUT = 0 ; in secs, 0 for unlimited
REDIS_RETRY_INTERVAL = 100 ; in secs
REDIS_READ_TIMEOUT = 10 ; in secs, 0 for unlimited
REDIS_CACHE_RESULT = true
REDIS_CACHE_EXPIRE_MODE = "ttl" ; "ttl" or "maxitem"
REDIS_CACHE_EXPIRE_TTL = 3600
REDIS_CACHE_RESET_TTL_ON_GET = true
REDIS_CACHE_MAX_ITEM = 100
REDIS_RESET_STATS_ON_START = true
REDIS_USER = ""
REDIS_PASSWORD = ""
; Default MMDB settings
[mmdb]
MMDB_DIR = "/usr/share/GeoIP/GeoLite2-City.mmdb"
MMDB_FALLBACK = "" ; use local mmdb as fallback, empty to disable
MMDB_RELOAD_CRON = "" ; reload GeoIP mmdb with Cron pattern, empty to disable
; IPsum settings
[ipsum]
IPSUM_ENABLE = false ; enabling this will increase memory usage
IPSUM_URL = "https://raw.githubusercontent.com/stamparm/ipsum/master/ipsum.txt"
IPSUM_DIR = "blacklist/ipsum.txt"
IPSUM_MAX_LINES = 100000
IPSUM_MIN_LEVEL = 2 ; >= 2 is recommended for lowering memory usage (~10MB for all levels)
IPSUM_UPDATE_CRON = "15 1 * * *" ; download new IPsum list at every 01:15, empty to disable