31 lines
862 B
Python
31 lines
862 B
Python
# -*- coding: utf-8 -*-
|
|
|
|
import os
|
|
|
|
path_of_current_file = os.path.abspath(__file__)
|
|
path_of_current_dir = os.path.split(path_of_current_file)[0]
|
|
|
|
# worker_class为sync会报错
|
|
# uvicorn.workers.UvicornWorker
|
|
worker_class = 'uvicorn.workers.UvicornWorker'
|
|
# workers = multiprocessing.cpu_count() * 2 + 1
|
|
workers = 1 # 按需启动的进程数
|
|
threads = 1 # 各进程包含的线程数
|
|
|
|
chdir = path_of_current_dir
|
|
|
|
worker_connections = 0
|
|
timeout = 0
|
|
max_requests = 0
|
|
graceful_timeout = 0
|
|
|
|
loglevel = 'info'
|
|
access_log_format = '%(t)s %(p)s %(h)s "%(r)s" %(s)s %(L)s %(b)s %(f)s" "%(a)s"'
|
|
reload = True
|
|
debug = False
|
|
bind = "%s:%s" % ("0.0.0.0", 14041)
|
|
pidfile = '%s/sadtalker.pid' % (path_of_current_dir)
|
|
errorlog = '%s/sadtalker.log' % (path_of_current_dir)
|
|
accesslog = '%s/sadtalker_access.log' % (path_of_current_dir)
|
|
proc_name = "sadtalker_api"
|