Skip to main content
Lender is a single Go service, packaged as a container and configured entirely through environment variables. This page is the operator’s reference: what it runs as, what it depends on, the settings that matter, and how tenancy and ledger routing behave.

The container


Lender builds from a multi-stage Dockerfile — a Go Alpine builder producing a static binary, copied into a distroless nonroot runtime — and listens on port 8080. It ships as a container image you deploy into your cluster with the platform’s standard lifecycle tooling; this page does not assume any particular packaging beyond the image. Operational probes:

Dependencies


Configuration surface


Configuration is entirely environment-driven. The keys below are a curated subset — the ones that shape behavior — not the full list.

Multi-tenant modes


Lender runs in one of two modes:
  • Single-tenant — one tenant (DEFAULT_TENANT_ID), one database schema, and a construction-time ledger organization and ledger used as the posting default.
  • Multi-tenant (MULTI_TENANT_ENABLED=true) — schema-per-tenant persistence, a per-tenant Midaz client pool, and tenant-scoped events and postings. In this mode there is no env ledger default: the ledger target comes per transaction from the product’s accounting profile.

Ledger posting and fails-closed routing


A booking reaches the ledger through a durable posting intent and an asynchronous relay — the full path is in Lender in the platform. The operationally important property: routing fails closed. A posting books into the ledger organization and ledger resolved from the accounting profile (single-tenant falls back to the env default); if neither resolves a non-empty target, Lender refuses to post rather than book into an empty or wrong ledger. Under multi-tenant mode, a product with no accounting profile therefore cannot post — which is the intended safeguard.

Next steps


Lender in the platform

The posting path, event catalog, and tenant isolation in detail.