mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-05 03:12:14 +00:00
fix(api): set gunicorn keep-alive above the load balancer idle timeout to stop 502s (#11647)
This commit is contained in:
@@ -56,6 +56,12 @@ preload_app = not DEBUG
|
||||
# that may take longer, such as complex API operations.
|
||||
timeout = env.int("GUNICORN_TIMEOUT", default=120)
|
||||
|
||||
# HTTP keep-alive idle timeout. Must exceed the idle timeout of the proxy or load
|
||||
# balancer in front of gunicorn, or it reuses a connection gunicorn just closed
|
||||
# and returns a 502. Default clears the common 60s; raise `GUNICORN_KEEPALIVE` to
|
||||
# stay above a longer one.
|
||||
keepalive = env.int("GUNICORN_KEEPALIVE", default=75)
|
||||
|
||||
# Logging
|
||||
logconfig_dict = DJANGO_LOGGERS
|
||||
gunicorn_logger = logging.getLogger(BackendLogger.GUNICORN)
|
||||
|
||||
Reference in New Issue
Block a user