diff --git a/gunicorn/config.py b/gunicorn/config.py index 2d8d73ac..ee10b9a5 100644 --- a/gunicorn/config.py +++ b/gunicorn/config.py @@ -98,8 +98,7 @@ class Config(object): @property def workers(self): - env_workers = int(os.environ.get('WEB_CONCURRENCY')) - return self.settings['workers'].get() or env_workers + return self.settings['workers'].get() @property def address(self): @@ -508,7 +507,7 @@ class Workers(Setting): meta = "INT" validator = validate_pos_int type = int - default = 1 + default = int(os.environ.get('WEB_CONCURRENCY', 1)) desc = """\ The number of worker process for handling requests.