-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
config.template.toml
28 lines (23 loc) · 1015 Bytes
/
config.template.toml
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
[SERVER]
host = "localhost"
port = 8181
session_secret = "" # Run: import secrets; print(secrets.token_urlsafe(64))
maintenance = false
[DATABASE]
dsn = "postgres://mystbin:mystbin@database:5432/mystbin"
[LIMITS]
paste_get = { rate = 30, per = 60, priority = 1, bucket = "ip" }
paste_get_day = { rate = 7200, per = 86400, priority = 2, bucket = "ip" }
paste_post = { rate = 10, per = 60, priority = 1, bucket = "ip" }
paste_post_day = { rate = 1440, per = 86400, priority = 2, bucket = "ip" }
global_limit = { rate = 21600, per = 86400, priority = 1, bucket = "ip" }
[PASTES]
char_limit = 300_000
file_limit = 5
name_limit = 25
[REDIS] # optional key
limiter = "redis://redis:6379/0" # required if key present
sessions = "redis://redis:6379/1" # required if key present
[GITHUB] # optional key
token = "..." # a github token capable of creating gists, non-optional if the above key is provided
timeout = 10 # how long to wait between posting gists if there's an influx of tokens posted. Non-optional