From c1d895e48fff3609b2bed71c9338877b3ee4daa4 Mon Sep 17 00:00:00 2001 From: RogerWork Date: Mon, 19 Feb 2024 08:24:15 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81gunicorn?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gunicorn_config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gunicorn_config.py b/gunicorn_config.py index 1b5b16c..a795d36 100644 --- a/gunicorn_config.py +++ b/gunicorn_config.py @@ -1,7 +1,7 @@ import os import multiprocessing -bind = '127.0.0.1:8000' # 指定监听的地址和端口,用于nginx转发 +bind = '0.0.0.0:8000' # 指定监听的地址和端口,用于nginx转发 backlog = 2048 # 服务器中排队等待的最大连接数,建议值64-2048,超过2048时client连接会得到一个error。 workers = multiprocessing.cpu_count() * 2 + 1 # 用于处理工作的进程数,这里使用了文档建议的值