mirror of
https://github.com/stardrophere/InsightRadar.git
synced 2026-06-05 23:56:36 +08:00
19 lines
315 B
Python
19 lines
315 B
Python
# run.py
|
|
import uvicorn
|
|
import os
|
|
from dotenv import load_dotenv
|
|
|
|
if __name__ == "__main__":
|
|
|
|
load_dotenv()
|
|
PORT = int(os.getenv("PORT", 8000))
|
|
|
|
# 启动服务
|
|
uvicorn.run(
|
|
app="app.main:app",
|
|
host="0.0.0.0",
|
|
port=PORT,
|
|
# reload=True,
|
|
workers=1
|
|
)
|