Product
Database
External Databases

External Databases

By default, every environment gets a PostgreSQL container deployed on its own server and fully managed by OEC.sh. If you already run PostgreSQL elsewhere — AWS RDS or Aurora, a managed cluster from DigitalOcean, Vultr, Hetzner, Azure, or Google Cloud SQL, or your own self-hosted instance — you can point an environment at it instead.

External databases require a Pro plan or above and the org.external_database.manage permission (Owner or Admin).


Step 1: Add a Connection

  1. Go to Settings > Database Connections
  2. Click Add Connection
  3. Fill in:
    • Name — a label to recognize this cluster by
    • Provider — AWS RDS, AWS Aurora, DigitalOcean Managed, Vultr Managed, Hetzner Managed, Azure Database, GCP Cloud SQL, Self-hosted, or Other (locked once the connection is created)
    • Host and Port (default 5432)
    • SSL Mode — Require (recommended), Verify CA, Verify Full, or Disable
    • Custom CA Certificate — only needed for Verify CA / Verify Full, paste your cluster's CA cert in PEM format
    • Admin Username and Admin Password — used once to create the environment's database, its dedicated user, and required extensions. OEC.sh never uses these credentials from your environment's Odoo container.
    • Replica Host / Port (optional) — an Aurora reader endpoint or RDS read replica, if you have one
  4. Click Add Connection. The platform runs a connection test automatically and shows a health badge (Healthy, Unreachable, Auth Failed, or Invalid Pooling).
⚠️

If your endpoint is a PgBouncer instance running in transaction-pooling mode, the test reports Invalid Pooling. Odoo requires session-pooling or a direct connection — point the host at the real PostgreSQL port (usually 5432) instead.

You can re-run the test anytime from the connection list, and edit or delete a connection later. A connection that's in use by one or more environments can't be deleted until those environments are moved off it.


Step 2: Use It on an Environment

When creating or editing an environment, the Database Provider section offers two options:

  • Use platform-managed PostgreSQL (recommended) — the default; a container on your server, fully managed by OEC.sh
  • Use your own database — pick a healthy connection from Step 1, then set a Database Name (lowercase letters, digits, underscores, or hyphens, 1–63 characters; leave blank to auto-generate one)
⚠️

Database provider can't be changed after the environment is created. Choose carefully at creation time.


Private Networks

If your database is only reachable on a private network (a VPC peering link, a private subnet, or a database that isn't exposed to the public internet at all), that's fully supported. OEC.sh provisions and health-checks the database from your environment's own server rather than from outside, so you never need to open your database up to the public internet for the platform to manage it.


What Works With External Databases

  • Connect As — signs in as any Odoo user the same way it does for a platform-managed database. See Connect As.
  • Database Terminal — opens directly into a psql prompt against your external cluster, same as for a platform-managed database.
  • Backups — manual and scheduled backups run against your external database the same way they do for platform-managed ones. See Backups.
  • Deployments — the platform automatically caps its own connection pool per deployment so it stays within your cluster's connection limit, even on a busy environment.

Troubleshooting

Health statusWhat it meansWhat to check
UnreachableThe platform can't reach the host/port from your environment's serverHostname and port are correct; the server accepts inbound connections from your environment; firewall rules
Auth FailedUsername or password didn't workDouble-check both, especially after a password rotation on the cluster
Invalid PoolingThe endpoint is PgBouncer in transaction-pooling modePoint the host at the real PostgreSQL port instead
UntestedNo connection test has run yetClick the test icon next to the connection