fix: ensure worker count is properly converted to integer for max_requests

This commit is contained in:
liqiang-fit2cloud 2025-11-07 11:18:02 +08:00 committed by CaptainB
parent 8f3cd55ad9
commit df1f1d6bd2

View File

@ -18,7 +18,7 @@ class SchedulerService(BaseService):
log_format = '%(h)s %(t)s %(L)ss "%(r)s" %(s)s %(b)s '
bind = f'127.0.0.1:6060'
max_requests = 10240 if self.worker > 1 else 0
max_requests = 10240 if int(self.worker) > 1 else 0
cmd = [
'gunicorn', 'maxkb.wsgi:application',
'-b', bind,