24 lines
441 B
Python
24 lines
441 B
Python
#!/usr/bin/env python3
|
|
"""
|
|
Main entry point for the FastAPI server
|
|
"""
|
|
import uvicorn
|
|
import os
|
|
from dotenv import load_dotenv
|
|
|
|
load_dotenv()
|
|
|
|
if __name__ == "__main__":
|
|
port = int(os.getenv("PORT", 8000))
|
|
host = os.getenv("HOST", "0.0.0.0")
|
|
reload = os.getenv("NODE_ENV") == "development"
|
|
|
|
uvicorn.run(
|
|
"src.main:app",
|
|
host=host,
|
|
port=port,
|
|
reload=reload,
|
|
log_level="info"
|
|
)
|
|
|