ADnD is a multiplayer tabletop RPG platform where a configurable AI Game Master runs your campaign. Players connect in real time over WebSockets, roll dice, manage characters, and watch the story unfold — all driven by an LLM backend you choose and control.
cp .env.example .env
Edit .env and fill in:
| Variable | Description |
|---|---|
POSTGRES_PASSWORD | PostgreSQL password |
JWT_SECRET_KEY | JWT signing key, min 32 bytes — generate with openssl rand -base64 48. The app refuses to start on a placeholder or a short key. |
JWT_ISSUER | JWT issuer string (e.g. adnd-server) |
JWT_AUDIENCE | JWT audience string (e.g. adnd-client) |
ENCRYPTION_MASTER_KEY | AES-256-GCM key — generate with openssl rand -base64 32 |
Optional settings (see .env.example for the full list):
| Variable | Default | Description |
|---|---|---|
SECURITY__ALLOW_PRIVATE_LLM_ENDPOINTS | true | Permits LLM presets to target private/LAN addresses, which self-hosted Ollama and LM Studio need. Set false when untrusted users can register. |
SWAGGER__ENABLED | Development only | Swagger UI cannot sit behind bearer auth, so it is not served in Production unless you opt in. |
HANGFIRE__DASHBOARD_ENABLED | false | The /hangfire dashboard. Off by default; pair with HANGFIRE__DASHBOARD_ALLOWED_IPS. |
docker compose up --build
This builds the .NET server (which also builds the Vite client inside Docker) and starts PostgreSQL. EF Core migrations run automatically on first start.
Open http://localhost:5010 in your browser.
/register| Provider | ProviderType | Notes |
|---|---|---|
| Ollama | ollama | Local; set EndpointUrl to http://host.docker.internal:11434 |
| LM Studio / any OpenAI-compatible | openaicompatible | Set EndpointUrl to your server's /v1 base URL |
| OpenAI | openai | Requires API key |
| Google AI Studio | google | Requires API key; supports ReasoningEffort |
Migrations are applied automatically on startup. To generate a new migration:
docker compose run --rm app-sdk dotnet ef migrations add <Name> --project src/Adnd.Server
Browser (React 19 + MUI)
│
├── REST /api/** — CRUD, auth, admin
└── WebSocket /gamehub — SignalR real-time events
│
Adnd.Server (.NET 10)
│
┌───────┴────────┐
PostgreSQL 17 Wolverine message bus
+ pgvector (PostgreSQL-backed sagas)
Key design principles:
docker compose up --build is the only workflow| Path | Description |
|---|---|
http://localhost:5010 | React SPA |
http://localhost:5010/swagger | API documentation — Development only unless SWAGGER__ENABLED=true |
http://localhost:5010/health | Liveness check (database only, so an LLM outage cannot restart-loop the container) |
http://localhost:5010/health/ready | Readiness check — also probes the configured LLM provider and pgvector |
http://localhost:5010/hangfire | Background job dashboard — requires HANGFIRE__DASHBOARD_ENABLED=true |
| Layer | Technology |
|---|---|
| Backend | ASP.NET Core 10 |
| ORM | EF Core 10 + Npgsql |
| Vector search | pgvector + HNSW indexes |
| Message bus | WolverineFx 6 (PostgreSQL-backed) |
| Background jobs | Hangfire (PostgreSQL-backed) |
| Real-time | ASP.NET Core SignalR |
| Auth | JWT HS256 + refresh token rotation |
| Frontend | React 19 + TypeScript + Vite 6 |
| UI | MUI v7 |
Content type
Image
Digest
sha256:6f6c255c7…
Size
116.1 MB
Last updated
6 days ago
docker pull jncchds/adnd