Smoooth
Architecture Pillar // 03

Stateful Database Adapters & Volume Locks

Provision and maintain persistent databases without risking catastrophic volume deletion during automated agent refactoring.

The Hazard of Ephemeral Container Management

AI coding agents naturally treat infrastructure as ephemeral: when prompted to "update the app" or "restart services", an agent using raw Docker CLI might execute docker compose down -v or recreate container volume mappings, destroying months of production records in milliseconds.

Dedicated Stateful Database Adapters

Smoooth provides dedicated lifecycle adapters for major open-source data stores:

Automatic Volume Locks (is_persistent: true)

# Declaring a persistent database via Smoooth manifest:
databases:
  - name: "prod-postgres"
    adapter: "postgres"
    version: "16"
    volume:
      path: "/var/lib/smoooth/volumes/prod-pgdata"
      retention_policy: "retain_on_delete"
      is_persistent: true   # Prevent agent destructive actions

When an adapter volume is marked with is_persistent: true, the Smoooth runtime prohibits any agent tool call from dropping, unmounting, or truncating the volume without an explicit confirmation signature from a human operator.

← Return to Features Overview · Next: Reverse Proxy →