-
Notifications
You must be signed in to change notification settings - Fork 112
Expand file tree
/
Copy pathgconf.py
More file actions
30 lines (26 loc) · 912 Bytes
/
gconf.py
File metadata and controls
30 lines (26 loc) · 912 Bytes
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
bind = '0.0.0.0'
try:
workers = int({{ if exists "/deis/controller/workers" }}{{ getv "/deis/controller/workers" }}{{ else }}"not set"{{end}})
except (NameError, ValueError):
import multiprocessing
try:
workers = multiprocessing.cpu_count() * 2 + 1
except NotImplementedError:
workers = 8
proc_name = 'deis-controller'
timeout = 1200
pidfile = '/tmp/gunicorn.pid'
loglevel = 'info'
errorlog = '-'
accesslog = '-'
access_log_format = '%(h)s "%(r)s" %(s)s %(b)s "%(a)s"'
def worker_int(worker):
"""Print a stack trace when a worker receives a SIGINT or SIGQUIT signal."""
worker.log.warning('worker terminated')
import traceback
traceback.print_stack()
def worker_abort(worker):
"""Print a stack trace when a worker receives a SIGABRT signal, generally on timeout."""
worker.log.warning('worker aborted')
import traceback
traceback.print_stack()