# Generate the secretkubectlcreatesecretgenericeddi-secrets\--namespace=eddi\--from-literal=EDDI_VAULT_MASTER_KEY="$(openssl rand -base6424)"\--dry-run=client-oyaml|kubectlapply-f-# Restart EDDI to pick up the keykubectlrolloutrestartdeployment/eddi-neddi# Access EDDIkubectlport-forwardsvc/eddi7070:7070-neddi
The component overlays (auth, nats, monitoring, etc.) are designed to be composed with a database overlay. They do not include the base EDDI manifests on their own.
Kustomize takes one directory as input. To combine components, create a kustomization.yaml that references multiple overlays:
Ready-made examples are provided in k8s/examples/:
Architecture on Kubernetes
Security
Vault Master Key
The vault master key encrypts all stored API keys and secrets. If you lose this key, encrypted secrets are unrecoverable.
Three ways to manage it:
Helper script (recommended for initial setup):
Manual kubectl:
External secrets (production): Use External Secrets Operator to sync from AWS Secrets Manager, HashiCorp Vault, Azure Key Vault, etc.
Pod Security
EDDI runs as non-root user (UID 185) and is compatible with restricted Pod Security Standards:
Network Policy
The production overlay includes a NetworkPolicy that restricts EDDI to:
Ingress: HTTP port 7070 from within the namespace + Ingress controllers
Egress: Database (MongoDB/PG), NATS, Keycloak, DNS, and external HTTPS (port 443 for LLM APIs)
Scaling
Single Replica (default)
Default configuration uses in-memory messaging — suitable for development and low-traffic deployments.
Multi-Replica (production)
For horizontal scaling, enable NATS JetStream for durable message ordering:
Kustomize:
Helm:
Monitoring
EDDI exposes Prometheus metrics at /q/metrics. The EDDI Deployment includes Prometheus scrape annotations by default:
Deploy the monitoring stack using the full example or Helm:
Health Checks
EDDI provides three probe endpoints:
Endpoint
Probe Type
Purpose
/q/health/live
Liveness
Process is alive
/q/health/ready
Readiness + Startup
DB connected, ready for traffic
/q/metrics
—
Prometheus metrics
File Structure
Note: Overlays marked (standalone) include the base and can be applied directly with kubectl apply -k. Overlays marked (component) must be composed with a standalone overlay — see Composing Kustomize Overlays.
Troubleshooting
EDDI pod stuck in CrashLoopBackOff
Check if the database is reachable:
Common causes:
MongoDB/PostgreSQL not yet ready (wait for StatefulSet pod)
Incorrect connection string in ConfigMap
Volume claims pending (check kubectl get pvc -n eddi)
EDDI starts but readiness probe fails
Check the health endpoint:
Vault key issues
If you see "vault master key not set" warnings, create the secret:
PVC stuck in Pending
If PVCs aren't provisioning, check your StorageClass:
If your cluster doesn't have a default StorageClass, uncomment storageClassName in the StatefulSet manifests.