Database, Managed (Neon)
Recommended Postgres setup for Olympus production
Neon is a managed PostgreSQL service with a generous free tier, branching, and automatic scaling. Olympus's Daedalus wizard supports Neon natively.
For most operators, managed Postgres is the right choice, self-hosting Postgres alongside Olympus on the same VPS is doable but adds a stateful service that you have to back up, monitor, and rotate certs for.
What Daedalus does
In the Database, Neon wizard step:
- Reads your Neon API key.
- Creates a Neon project (or uses an existing one you select).
- Provisions five databases inside the project:
ciam_kratos,ciam_hydra,iam_kratos,iam_hydra,olympus. - Generates a strong password for each.
- Records the per-database
DATABASE_URL(withsslmode=verify-fulland the Neon CA bundle) in the deployment context.
Why Neon
- Branching, each commit can have its own ephemeral Postgres branch for migration testing. Olympus doesn't use this in CI yet but the option exists.
- Compute-only billing, pay for CPU minutes, not provisioned capacity. Olympus's auth traffic is bursty; this saves money.
- Free tier, sufficient for ~1k MAU.
- TLS by default with
verify-fullsupport. - EU-resident options for GDPR compliance.
Connection details
Each of the five databases gets its own connection string:
postgres://ciam_kratos_user:<pass>@<endpoint>.neon.tech/ciam_kratos?sslmode=verify-full&sslrootcert=neon-ca.crtThe Neon CA bundle is fetched once during deployment and stored at /etc/ssl/certs/neon-ca.crt inside each app container. See Deploy, Database SSL verify-full for the full rationale.
Connection pooling
Olympus uses a postgres-js-based pool in the SDK (default max: 10 per app instance). With four Ory services and three app services per domain, the pool count per Neon endpoint is ~40 connections. Neon's free tier allows 100 connections; the next tier is 1000.
If you see "too many connections" errors, lower the SDK pool size via SDK_POOL_MAX=5 env var on each app.
Backups
Neon automatically retains every commit for 7 days (free tier) or 30 days (paid). Point-in-time recovery is one click.
For belt-and-suspenders backups, run nightly pg_dump against each of the five databases, see Operate, Backups (Postgres).
Pricing estimate
For a 1k-MAU Olympus deployment:
- Compute: ~10 hours active CPU/month (auth traffic is light) = ~$3
- Storage: ~500MB across all five DBs = $0.15
- Total: ~$3-5/month on the paid tier.
The free tier covers smaller deployments entirely.
When Neon isn't the right answer
- No internet egress from your VPS (e.g. air-gapped deployments), use self-hosted Postgres.
- You need >1000 concurrent connections, Neon's connection limits become a bottleneck at significant scale.
- You're already operating a Postgres cluster, use that instead.
Where next
- Deploy, Database SSL verify-full, the production TLS contract.
- Operate, Backups (Postgres)
- Deploy, First production deploy