Fix start.py environment logic and Finalize Master Admin
This commit is contained in:
parent
4c42f55e14
commit
5df43f47da
12
start.py
12
start.py
|
|
@ -64,8 +64,12 @@ def start_daemon():
|
|||
return
|
||||
|
||||
print("🚀 Starting SexChat in background...")
|
||||
gunicorn_bin = os.path.join(os.path.dirname(__file__), ".venv", "bin", "gunicorn")
|
||||
if not os.path.exists(gunicorn_bin):
|
||||
gunicorn_bin = "gunicorn" # fallback
|
||||
|
||||
cmd = [
|
||||
"gunicorn",
|
||||
gunicorn_bin,
|
||||
"--worker-class", "eventlet",
|
||||
"-w", "1",
|
||||
"--bind", f"{_get_conf('HOST', '0.0.0.0')}:{_get_conf('PORT', 5000)}",
|
||||
|
|
@ -120,8 +124,12 @@ def get_status():
|
|||
|
||||
def run_debug():
|
||||
print("🛠️ Starting SexChat in DEBUG mode (foreground)...")
|
||||
gunicorn_bin = os.path.join(os.path.dirname(__file__), ".venv", "bin", "gunicorn")
|
||||
if not os.path.exists(gunicorn_bin):
|
||||
gunicorn_bin = "gunicorn" # fallback
|
||||
|
||||
cmd = [
|
||||
"gunicorn",
|
||||
gunicorn_bin,
|
||||
"--worker-class", "eventlet",
|
||||
"-w", "1",
|
||||
"--bind", f"{_get_conf('HOST', '0.0.0.0')}:{_get_conf('PORT', 5000)}",
|
||||
|
|
|
|||
Loading…
Reference in New Issue