diff --git a/lifecycle/gunicorn.conf.py b/lifecycle/gunicorn.conf.py index e03372481..211f78680 100644 --- a/lifecycle/gunicorn.conf.py +++ b/lifecycle/gunicorn.conf.py @@ -51,7 +51,8 @@ logconfig_dict = { if SERVICE_HOST_ENV_NAME in os.environ: workers = 2 else: - workers = int(os.environ.get("WORKERS", cpu_count() * 2 + 1)) + default_workers = max(cpu_count() * 0.25, 1) + 1 # Minimum of 2 workers + workers = int(os.environ.get("WORKERS", default_workers)) threads = 4 warnings.simplefilter("once")