Lantern splits into a control plane (scheduling, routing, dashboard) and a data plane (microVMs, execution, secrets). The data plane runs in your cloud — agent data never leaves your VPC.
In plain termsTwo halves: the control plane is the brain (dashboards, scheduling, budgets — it decides what should run), and the data plane is the muscle (where agent code actually executes, with your API keys and your data). The point of the split: you can keep the muscle inside your own cloud account, so prompts, credentials, and customer data never leave your infrastructure — while the brain is run for you as a service. Pick the mix that fits: fully managed, hybrid, or everything self-hosted.
Architecture — the CP/DP split
The full system: channels → gateways → control plane → your data plane. The control plane never runs user code.
What crosses the boundary: specs, identity, and trace context go down; heartbeats, step events, and audit come back. Token-authenticated (mTLS hardening planned) — prompts and data never leave your VPC.
Deployment options
Fully managed (Lantern Cloud)
Both planes hosted by Lantern. No infrastructure to manage. Sign up at lantern.run, create agents from the dashboard, everything runs on Lantern infrastructure.
Best for: getting started and workloads without strict data residency requirements.
Hybrid (recommended for production)
Control plane hosted by Lantern; data plane in your cloud. Agent data stays in your VPC.
Deploy the data plane Helm chart into your cluster (see below).
Register via POST /v1/data-planes or Settings → Data Planes. This mints a one-time 32-byte bootstrap token — store it immediately.
The data plane dials out to :50051 (gRPC), sends the bootstrap token via Register RPC, and receives a short-lived session JWT (1 h TTL, auto-rotated via RefreshToken).
The data plane opens a persistent RunStream bidi RPC. The control plane pushes run assignments; the agent reports status and completion back. Only run metadata crosses the boundary.
Tunnel RPCs
Defined in packages/proto/lantern/v1/dataplane.proto, served on the control plane's :50051 listener.
Terraform modules for EKS, GKE, and AKS are generated by lantern infra install — they are not yet published to the Terraform Registry. Run the CLI command to generate the config, review the output, then terraform apply.
lantern infra install # generates terraform/ in the current directory
cd terraform
terraform init
terraform plan
terraform apply
Namespace isolation
Each tenant gets its own Kubernetes namespace: lantern-t-<tenant_id>. Provides network isolation, per-tenant resource quotas, and separate service accounts and secrets.
Monitoring
Every service emits OTel traces tagged with tenant_id, run_id, step_id, and agent_version. Compatible with Grafana + Tempo, Datadog, New Relic, Jaeger, and any OTel backend. Production alert rules, Grafana dashboards, and runbooks live in infra/monitoring/ and docs/runbooks/. See Observability for details.
Database migrations
The control plane manages its Postgres schema via golang-migrate. Migrations are embedded SQL shipped inside the binary.
Fresh databases — migration 0001 creates the full schema on first boot.
Existing databases — 0001 is fully IF NOT EXISTS; running it records version 1 in schema_migrations with no DDL changes.
New changes — sequential pairs (0002_*.up.sql / 0002_*.down.sql). Down migrations required after the baseline.
Only the control plane runs migrations. Other services read and write tables but never apply schema changes.