-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathgunicorn.conf.py
More file actions
58 lines (56 loc) · 1.45 KB
/
gunicorn.conf.py
File metadata and controls
58 lines (56 loc) · 1.45 KB
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
from __future__ import annotations
accesslog = None
errorlog = "-"
timeout = 120 # 2 minutes; during imports
capture_output = True
loglevel = "info"
forwarded_allow_ips = "*"
access_log_format = '%({x-forwarded-for}i)s %(l)s %(u)s %(t)s "%(r)s" %(s)s %(b)s "%(f)s" "%(a)s"'
logconfig_dict = {
"version": 1,
"disable_existing_loggers": False,
"filters": {
"health_endpoint": {
"()": "config.logging_filters.HealthEndpointFilter",
},
"hetrix_access": {
"()": "config.logging_filters.HetrixAccessFilter",
},
},
"formatters": {
"access": {
"format": "%(message)s",
},
"error": {
"format": "[{asctime}] {levelname} {name}: {message}",
"style": "{",
},
},
"handlers": {
"stdout": {
"class": "logging.StreamHandler",
"formatter": "access",
},
"stderr": {
"class": "logging.StreamHandler",
"formatter": "error",
},
},
"loggers": {
"gunicorn.error": {
"handlers": ["stderr"],
"level": "INFO",
"propagate": False,
},
"gunicorn.access": {
"handlers": ["stdout"],
"level": "WARNING",
"filters": ["health_endpoint", "hetrix_access"],
"propagate": False,
},
},
"root": {
"handlers": ["stderr"],
"level": "INFO",
},
}