Developer
Local setup
Run the full Ragnarock stack on your machine.
Complete local stack: infrastructure in Docker, NestJS API, FastAPI agent, Next.js frontend, and this docs site.
Prerequisites
| Tool | Version |
|---|---|
| Bun | 1.3+ (backend) |
| pnpm | 9+ (frontend, docs) |
| Docker | Desktop or Engine |
| Python | 3.11+ (agent, optional if using Docker agent) |
1. Infrastructure
From ragnarock-backend:
make upOr explicitly:
docker compose -f docker/development/docker-compose.yml up -d| Service | Port | Purpose |
|---|---|---|
| PostgreSQL | 5432 | Prisma / app data |
| pgvector memory | 5433 | Agent embeddings |
| Redis | 6379 | Sessions, AI queues |
| Typesense | 8108 | User search |
| Mailpit SMTP | 1025 | Outbound mail capture |
| Mailpit UI | 8025 | Read dev emails |
2. Backend API
cd ragnarock-backend
cp .env.example .env
bun install
bun run prisma:generate
bun run prisma:migrate:dev
bun run start:dev- API: http://localhost:8000
- Scalar docs: http://localhost:8000/docs
- Auth: http://localhost:8000/api/auth
Use DATABASE_URL with host localhost when running the API on your machine (not inside
Docker). Compose defaults use service name postgres.
3. Agent worker
cd ragnarock-agent
cp .env.example .env
# Set LLM_PROVIDER and API keys, REDIS_URL, DATABASE_URL
pip install -r requirements.txt
./run.shHealth: http://localhost:8100/health
Or start via staging compose (agent service on port 8100).
4. Frontend
cd ragnarock
# create .env.local
pnpm install
pnpm devNEXT_PUBLIC_API_URL=http://localhost:80005. Documentation site
cd ragnarock-docs
cp .env.example .env.local
pnpm install
pnpm devOptional Ask AI: set OPENROUTER_API_KEY in .env.local.
Key environment variables
Prop
Type
Verify the stack
curl http://localhost:8000 — API responds.curl http://localhost:8100/health — agent healthy.Sign up at
http://localhost:3000 — check Mailpit for verification email.Create a project and send a Ragnarock chat message — watch agent logs.
Troubleshooting: Common issues.