Installation
Server
HiveGuard is distributed as a Docker image. The recommended way to run it is Docker Compose.
Docker Compose (recommended)
git clone https://github.com/your-org/hiveguardcd hiveguarddocker compose up --build -dThe docker-compose.yml starts:
api— FastAPI server on port 8000db— PostgreSQLredis— session cache and config store
From source (development)
git clone https://github.com/your-org/hiveguardcd hiveguarduv sync --frozen --extra devuv run uvicorn hiveguard.main:app --reloadRequires PostgreSQL and Redis running locally. Set environment variables:
export DATABASE_URL=postgresql+asyncpg://user:pass@localhost/hiveguardexport REDIS_URL=redis://localhost:6379export TARGET_URL=http://localhost:8080export SECRET_KEY=dev-secretexport DASHBOARD_USERNAME=adminexport DASHBOARD_PASSWORD=adminCLI
pip / uv (recommended)
pip install hiveguard-cli# oruv pip install hiveguard-clipipx (isolated, no venv management)
pipx install hiveguard-cliFrom the monorepo
uv pip install -e apps/cliVerify
hiveguard --versionhiveguard healthDashboard
The dashboard SPA is embedded in the server. Open http://localhost:8000/dashboard in your browser and log in with your DASHBOARD_USERNAME / DASHBOARD_PASSWORD.
No separate installation needed.
Environment variables
| Variable | Required | Default | Description |
|---|---|---|---|
TARGET_URL | yes | — | The upstream service HiveGuard proxies to |
DATABASE_URL | yes | — | PostgreSQL async URL (postgresql+asyncpg://...) |
SECRET_KEY | yes | — | Random string for session signing |
DASHBOARD_USERNAME | yes | — | HTTP Basic username for dashboard access |
DASHBOARD_PASSWORD | yes | — | HTTP Basic password for dashboard access |
REDIS_URL | no | redis://redis:6379 | Redis connection URL |
LOG_LEVEL | no | INFO | Python logging level |