Aegra - self-hosted LangGraph Platform alternative. Multi-arch, signed, SBOM.
583
Multi-arch (amd64, arm64), signed container images for Aegra, the open-source, self-hosted alternative to LangGraph Platform.
Community-maintained by upstreamyard. This is not an official Aegra image. Aegra is © its authors and licensed under Apache-2.0 (license text in
/licenses/aegra/LICENSEinside the image).
| Registry | Image |
|---|---|
| Docker Hub | upstreamyard/aegra |
| GitHub Container Registry | ghcr.io/upstreamyard/aegra |
Tags: latest, <major>.<minor> (e.g. 0.10), <version> (e.g. 0.10.8, matching the Aegra releases). New Aegra releases are built automatically within 24 hours.
| Port | 2026 |
| Probes | liveness GET /live, readiness GET /ready, full health GET /health |
| API docs | GET /docs, GET /openapi.json |
| Requires | PostgreSQL with the pgvector extension, e.g. pgvector/pgvector:pg18 (DATABASE_URL). Redis only for multiple replicas |
| Runs as | non-root UID 10001 |
| Migrations | automatic on startup, or aegra db upgrade |
| Default auth | none: the bundled example agents accept every request. Add an auth handler in your aegra.json (see below) |
AI agents and coding assistants: read AGENTS.md for deployment rules, and llms.txt for an index of all docs.
Aegra needs PostgreSQL with the pgvector extension; the pgvector/pgvector:pg18 image is Postgres 18 with pgvector included (Aegra requirement). Redis is optional and only needed when you run several replicas.
curl -O https://raw.githubusercontent.com/upstreamyard/aegra/main/docker-compose.yml
export OPENAI_API_KEY=sk-...
docker compose up -d
curl http://localhost:2026/ready
Or with plain docker run:
docker run -d -p 2026:2026 \
-e DATABASE_URL=postgresql://user:password@your-postgres:5432/aegra \
-e OPENAI_API_KEY=sk-... \
upstreamyard/aegra:latest
Point any LangGraph SDK client at http://localhost:2026.
Aegra runs your agent code. The image provides the server and its dependencies; you add a folder with your files:
my-agents/
├── aegra.json # which graphs to serve (and optionally which auth handler)
├── graph.py # your LangGraph graph(s)
└── my_auth.py # optional: authentication handler
{
"graphs": { "agent": "./graph.py:graph" },
"auth": { "path": "./my_auth.py:auth" }
}
Paths in aegra.json are relative to the folder containing aegra.json.
Put your folder under
/app(e.g./app/agents) and pointAEGRA_CONFIGat it.aegra serveignores anAEGRA_CONFIGoutside its working directory/appand silently serves the bundled example agents instead. See Aegra's docs for writing graphs and the auth handler.
Works when your code only uses packages that are already in the image. This is best for development, since you can edit files and restart without rebuilding.
docker run -d -p 2026:2026 \
-e DATABASE_URL=postgresql://user:password@your-postgres:5432/aegra \
-e AEGRA_CONFIG=/app/agents/aegra.json \
-v ./my-agents:/app/agents:ro \
upstreamyard/aegra:0.10
With Docker Compose, add the same AEGRA_CONFIG variable and a volumes: ["./my-agents:/app/agents:ro"] entry to the aegra service. The Helm chart can't mount files yet, so on Kubernetes use option 2.
Needed when your code uses extra Python packages, e.g. for Salesforce or Microsoft Teams, and the usual way to ship agents to Kubernetes:
FROM upstreamyard/aegra:0.10
USER root
RUN pip install --no-cache-dir simple-salesforce msgraph-sdk
USER 10001:10001
COPY my-agents/ /app/agents/
ENV AEGRA_CONFIG=/app/agents/aegra.json
docker build -t registry.example.com/my-agents:1.0 .
docker push registry.example.com/my-agents:1.0
Pinning 0.10 gets you Aegra's patch releases (and our image fixes) whenever you rebuild. With the Helm chart, deploy it with --set image.repository=registry.example.com/my-agents --set image.tag=1.0.
Never put API keys or passwords into the image. Pass them as environment variables when the container starts, and read them in your code with os.environ["SALESFORCE_TOKEN"]:
docker run: -e SALESFORCE_TOKEN=... or --env-file .envenvironment: or env_file:extraEnv for plain values, extraEnvFrom for a Kubernetes Secret:extraEnvFrom:
- secretRef:
name: salesforce-credentials # kubectl create secret generic salesforce-credentials --from-literal=SALESFORCE_TOKEN=...
All of Aegra's settings are environment variables. See the Aegra project's .env.example for the full list. The most important ones:
| Variable | Default in image | Notes |
|---|---|---|
DATABASE_URL | – | postgresql://user:pass@host:5432/db (or set POSTGRES_HOST, POSTGRES_USER, …) |
AEGRA_CONFIG | /app/aegra.json | Path to your graph config |
PORT / HOST | 2026 / 0.0.0.0 | |
RUN_MIGRATIONS_ON_STARTUP | true | Set false for multi-replica deployments and run aegra db upgrade as a one-off job |
REDIS_BROKER_ENABLED / REDIS_URL | false | Needed for multiple replicas (shared streaming and job queue) |
ENV_MODE | PRODUCTION | JSON logs |
ENABLE_PROMETHEUS_METRICS | false | Exposes /metrics |
The recommended way is the Helm chart (upstreamyard/helm-charts). It runs migrations as a Helm pre-install/pre-upgrade Job before pods start, which is the approach Aegra's docs recommend:
helm repo add upstreamyard https://upstreamyard.github.io/helm-charts
helm install aegra upstreamyard/aegra --set database.url='postgresql://user:password@host:5432/aegra'
Without Helm, examples/kubernetes/aegra.yaml is a plain-manifest starting point (Secret, migration Job, Deployment with probes, Service).
For more than one replica (the chart does all of this for you):
command: ["aegra", "db", "upgrade"].RUN_MIGRATIONS_ON_STARTUP=false, REDIS_BROKER_ENABLED=true and REDIS_URL on the Deployment./live for liveness and startup probes and /ready for readiness. Avoid /health for liveness: it fails when the database is down, and Kubernetes would then restart pods that are fine.The container runs as non-root UID 10001 and is compatible with runAsNonRoot: true.
Images are signed keylessly with cosign and include an SBOM and SLSA provenance:
cosign verify upstreamyard/aegra:latest \
--certificate-identity-regexp '^https://github.com/upstreamyard/aegra/' \
--certificate-oidc-issuer https://token.actions.githubusercontent.com
docker buildx imagetools inspect upstreamyard/aegra:latest --format '{{ json .SBOM }}'
.github/workflows/build.yml checks out the Aegra release tag and builds Dockerfile. Before publishing, it starts the image against a real PostgreSQL and waits for /health to pass. Everything is public and reproducible.
Differences from the Aegra project's own deployments/docker/Dockerfile: the aegra CLI is installed (so the default aegra serve command works), tini runs as PID 1, there's a built-in HEALTHCHECK, the UID is fixed, and builds are multi-arch.
Issues with the image: open an issue here. Issues with Aegra itself: aegra/aegra.
Content type
Image
Digest
sha256:aab0b4275…
Size
141.3 MB
Last updated
3 days ago
docker pull upstreamyard/aegra