Run JARVIS locally — Keycloak dev auth
Goal
You will bring up a full JARVIS stack locally with the Keycloak dev STS profile (JWT + token exchange).
When to use this
- You want a local environment closer to production auth flows.
- You want to validate service-to-service token exchange.
Prerequisites
- Docker + Docker Compose
- Python
>=3.11+pip(forarp-jarvis) - A local checkout of
JARVIS_Release
Steps
-
Create a local env file:
cd JARVIS_Release
cp compose/.env.example compose/.env.local -
Keep the default profile:
# in compose/.env.local
# STACK_PROFILE=dev-secure-keycloak -
Install the CLI:
python3 -m pip install -e .
arp-jarvis versions -
Start the stack and verify wiring:
arp-jarvis stack pull
arp-jarvis stack up -d
arp-jarvis doctor -
Log in once (device/browser flow) and start a run:
arp-jarvis auth login
arp-jarvis runs start --goal "Generate a UUID, then return it."Default dev user in the local realm (for the browser step):
- username:
dev - password:
dev
- username:
Verify
arp-jarvis doctorshows Run Gateway, Run Coordinator, and Keycloak as healthy.- Keycloak is reachable on
http://localhost:8080(default).
Troubleshooting
- Health is
degradedbecause Keycloak isn’t ready yet → wait 10–30 seconds, then retry; checkarp-jarvis stack logs -f keycloak. - You changed
KEYCLOAK_HOST_PORTbut did not updateARP_AUTH_ISSUER→ updateARP_AUTH_ISSUERincompose/profiles/dev-secure-keycloak.env. - You see auth errors between services → confirm the
ARP_*_CLIENT_SECRETvalues incompose/.env.localmatchcompose/keycloak/realm-arp-dev.json.
Cleanup / Rollback
-
Stop the stack (keeps volumes):
arp-jarvis stack down
Docker Compose fallback (no CLI)
docker compose --env-file compose/.env.local -f compose/docker-compose.yml up -d
curl -sS http://localhost:8081/v1/health
Next steps
- Concept: Policy checkpoints
- Reference: Authentication in JARVIS
- How-to: Start a run (Run Gateway)