Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions app/backend/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,16 @@ set -euo pipefail
# -----------------------------------------------------------------------------

SEED_DB=${SEED_DB:-false}
APP_MODULE=${APP_MODULE:-app/main.py}
APP_MODULE=${APP_MODULE:-src/main.py}
UV_CMD=${UV_CMD:-uv run}

export PYTHONUNBUFFERED=1
export PYTHONPATH=.

if [[ "$SEED_DB" == "true" ]]; then
echo "Seeding the database..."
$UV_CMD app/cli.py init-db
$UV_CMD app/cli.py seed --with-model=True
$UV_CMD src/cli.py init-db
$UV_CMD src/cli.py seed --with-model=True
fi

echo "Starting FastAPI server..."
Expand Down
9 changes: 7 additions & 2 deletions app/backend/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,12 @@ async def lifespan(_: FastAPI): # type: ignore # noqa: ANN201
yield


app = FastAPI(lifespan=lifespan)
app = FastAPI(
lifespan=lifespan,
openapi_url="/api/openapi.json",
redoc_url=None,
docs_url=None,
)
app.include_router(project_router)
app.include_router(job_router)
app.include_router(media_router)
Expand Down Expand Up @@ -154,5 +159,5 @@ def format_location(loc: Sequence[str | int]) -> str:


if __name__ == "__main__":
uvicorn_port = int(os.environ.get("HTTP_SERVER_PORT", "4999"))
uvicorn_port = int(os.environ.get("HTTP_SERVER_PORT", "7860"))
uvicorn.run("main:app", host="0.0.0.0", port=uvicorn_port) # noqa: S104
2 changes: 1 addition & 1 deletion app/ui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ npm run preview

Use the following commands to test your changes.

```
```bash
npm run format
npm run lint
npm run type-check
Expand Down
Loading
Loading