Docker
Run InitRunner in a container without installing Python or managing dependencies. Images ship with the dashboard, all model providers, ingestion, and safety extras pre-installed.
Images
Official images are published to both registries:
| Registry | Image |
|---|---|
| GitHub Container Registry | ghcr.io/vladkesler/initrunner:latest |
| Docker Hub | vladkesler/initrunner:latest |
Both are identical — use whichever your environment prefers.
Quick Start
One-shot prompt
docker run --rm -e OPENAI_API_KEY \
-v ./roles:/roles \
ghcr.io/vladkesler/initrunner:latest \
run /roles/my-agent.yaml -p "Hello"Interactive chat
docker run --rm -it -e OPENAI_API_KEY \
-v ./roles:/roles \
ghcr.io/vladkesler/initrunner:latest \
run /roles/my-agent.yaml -iWeb dashboard
docker run -d -e OPENAI_API_KEY \
-v ./roles:/roles \
-v initrunner-data:/data \
-p 8420:8420 \
ghcr.io/vladkesler/initrunner:latest \
ui --role-dir /rolesOpen http://localhost:8420 to access the dashboard.
Docker Compose
Create a docker-compose.yml:
services:
initrunner:
# GHCR (default) — or use vladkesler/initrunner:latest (Docker Hub)
image: ghcr.io/vladkesler/initrunner:latest
# build: . # uncomment to build from source
ports:
- "8420:8420" # Web dashboard
- "8000:8000" # API server
volumes:
- ./roles:/roles
- initrunner-data:/data
environment:
- OPENAI_API_KEY=${OPENAI_API_KEY:-}
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-}
- GOOGLE_API_KEY=${GOOGLE_API_KEY:-}
restart: unless-stopped
command: ["ui", "--role-dir", "/roles"]
volumes:
initrunner-data:Start the stack:
docker compose up -dBuilding Locally
Build the image from the repository root:
docker build -t initrunner .
docker run --rm initrunner --versionCustomizing extras
The default image includes dashboard, ingest, all-models, and safety. Override with a build arg:
docker build --build-arg EXTRAS="dashboard,anthropic" -t initrunner-custom .Environment Variables
Pass API keys and configuration as environment variables:
| Variable | Description |
|---|---|
OPENAI_API_KEY | OpenAI API key |
ANTHROPIC_API_KEY | Anthropic API key |
GOOGLE_API_KEY | Google API key |
INITRUNNER_HOME | Data directory inside the container (defaults to /data) |
Volumes
| Container Path | Purpose |
|---|---|
/roles | Mount your role YAML files here |
/data | Persistent state — sessions, memory, vector indexes |
Ports
| Port | Service |
|---|---|
8000 | API server (initrunner serve) |
8420 | Web dashboard (initrunner ui) |
Ollama Integration
If Ollama runs on the host machine, the container cannot reach localhost. Use the Docker host gateway address in your role YAML:
spec:
model:
provider: ollama
base_url: http://host.docker.internal:11434/v1