File size: 526 Bytes
1abd012
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
# Gunicorn configuration file
import multiprocessing

# Server socket
bind = "0.0.0.0:5000"

# Worker processes
workers = 2
worker_class = "sync"
threads = 2

# Timeout settings
timeout = 120
keepalive = 2

# Server mechanics
preload_app = True

# Logging
accesslog = "-"
errorlog = "-"
loglevel = "info"

# Health check settings
def on_starting(server):
    print("Gunicorn server is starting up...")

def when_ready(server):
    print("Gunicorn server is ready. Health check should now respond.")