Spaces:
Sleeping
Sleeping
| """ | |
| Server entry point for OpenEnv deployment. | |
| This module re-exports the FastAPI app from the root app module | |
| and provides a main() function for the [project.scripts] entry point. | |
| """ | |
| from __future__ import annotations | |
| import sys | |
| import os | |
| # Add project root to path so env/ package is importable | |
| sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) | |
| from app import app # noqa: E402 | |
| def main() -> None: | |
| """Entry point for the serve script.""" | |
| import uvicorn | |
| uvicorn.run("server.app:app", host="0.0.0.0", port=7860, reload=False) | |
| if __name__ == "__main__": | |
| main() | |