-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
34 lines (27 loc) · 814 Bytes
/
main.py
File metadata and controls
34 lines (27 loc) · 814 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/usr/bin/env python3
"""
Chatterbox TTS API Entry Point
This is the main entry point for the application.
It imports the FastAPI app from the organized app package.
"""
import uvicorn
from app.config import Config
def main():
"""Main entry point"""
try:
Config.validate()
print("Starting Chatterbox TTS API server...")
print(f"Server will run on http://{Config.HOST}:{Config.PORT}")
print(f"API documentation available at http://{Config.HOST}:{Config.PORT}/docs")
uvicorn.run(
"app.main:app",
host=Config.HOST,
port=Config.PORT,
reload=False,
access_log=True,
)
except Exception as e:
print(f"Failed to start server: {e}")
exit(1)
if __name__ == "__main__":
main()