-
Notifications
You must be signed in to change notification settings - Fork 1
/
.env.example
34 lines (31 loc) · 1.83 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
## Database configuration
# DB_DRIVER=pymysql
# DB_HOST=localhost
# DB_PORT=3306
DB_USER=policyd-rate-guard
DB_PASSWORD=Example1234
DB_DATABASE=policyd-rate-guard
## DB connection pool configuration
## See https://webwareforpython.github.io/DBUtils/main.html#pooleddb-pooled-db
# DB_POOL_MINCACHED=0
# DB_POOL_MAXCACHED=10
# DB_POOL_MAXSHARED=10
# DB_POOL_MAXUSAGE=10000
## PolicydRateGuard configuration
# QUOTA=1000 # The default quota for a user (default: 1000)
# ACTION_TEXT_BLOCKED="Rate limit reached, retry later." # Here you can put a custom message to be shown to a user who is over the ratelimit.
# SOCKET="/var/spool/postfix/rateguard/policyd" # Use this for unix socket
# SOCKET="127.0.0.1,10033" # Use this for IPv4 TCP socket
# SOCKET="[::1],10033" # Use this for IPv6 TCP socket
# LOG_LEVEL=INFO # DEBUG, INFO, WARNING, ERROR, CRITICAL
# LOG_FILE=/var/log/policyd-rate-guard/policyd-rate-guard.log
LOG_MSG_PREFIX=False # True or False (default: True) - Prefix log messages with caller filename and class/method
LOG_CONSOLE=True # True or False (default: False) - Output logs to console (stderr)
# SYSLOG=True # True or False (default: False) - Send logs to syslog
# SENTRY_DSN=https://**********.ingest.sentry.io/XXXXXXXXXXXXXXXX # Your Sentry DSN (default: None)
# SENTRY_ENVIRONMENT=prod
# MESSAGE_RETENTION=90 # How many days to keep messages in the database (default: 0, never delete)
# WEBHOOK_ENABLED=True # True or False (default: False) - Enable webhook
# WEBHOOK_USE_JWT=True # True or False (default: False) - Use JWT for webhook token authentication
# WEBHOOK_URL="https://example.com/api/policyd/{sender}?token={token}" # Webhook URL to trigger sender limit reached notification (default: None)
# WEBHOOK_SECRET="XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX=" # Webhook secret to generate token for remote API authentication (default: None)