Files
Django/gunicorn.conf.py

29 lines
583 B
Python
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Gunicorn 生产配置systemd 与 1Panel 共用)
# 远程 MySQL 时 worker×threads 不宜过大,否则打满 DB 连接 → 全站挂起
bind = "127.0.0.1:8001"
workers = 4
threads = 2
worker_class = "gthread"
timeout = 120
graceful_timeout = 30
keepalive = 2
max_requests = 2000
max_requests_jitter = 100
accesslog = None
errorlog = "/tmp/gunicorn-error.log"
loglevel = "warning"
preload_app = False
proc_name = "a_long_dianjing_gunicorn"
worker_tmp_dir = "/dev/shm"
daemon = False
limit_request_line = 4094
limit_request_fields = 100
limit_request_field_size = 8190