Skip to content

Commit a70ef43

Browse files
committed
Improve Gunicorn logging config
1 parent 5c241de commit a70ef43

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Procfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
release: python manage.py migrate
2-
web: gunicorn config.wsgi:application
2+
web: gunicorn config.wsgi:application --error-logfile "/dev/null" --access-logfile "/dev/null"
33
worker: REMAP_SIGTERM=SIGQUIT celery -A styleguide_example.tasks worker -l info --without-gossip --without-mingle --without-heartbeat
44
beat: REMAP_SIGTERM=SIGQUIT celery -A styleguide_example.tasks beat -l info --scheduler django_celery_beat.schedulers:DatabaseScheduler

gunicorn.conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ def gunicorn_event_name_mapper(logger, name, event_dict):
125125
"formatters": {
126126
"json_formatter": {
127127
"()": structlog.stdlib.ProcessorFormatter,
128-
"processor": structlog.processors.JSONRenderer(),
128+
"processor": structlog.processors.LogfmtRenderer(),
129129
"foreign_pre_chain": pre_chain,
130130
}
131131
},

0 commit comments

Comments
 (0)