Files
material-api/web/server_waitress.py
2024-05-29 10:21:31 +08:00

15 lines
268 B
Python

from os import cpu_count
from waitress import serve
from core.app import app
from core.conf import PORT
if __name__ == '__main__':
serve(
app,
host='0.0.0.0',
port=PORT,
threads=int(cpu_count()) # int(2 * cpu_count() + 1)
)