Quick start
The PostgreSQL backend for Silo (pgsilo) is in MVP development and has not been publicly released. The package names and commands below come from the local schema 14 build; no public download URL exists yet.
This guide prepares a PostgreSQL database, starts a writable Silo gateway in PostgreSQL mode, creates a bucket and a restricted application user, and writes objects over both S3 and SQL. For full host, certificate and macOS setup, see Install.
Prepare PostgreSQL
Use PostgreSQL 16 or later. Connect gateways directly to the writable primary, not through PgBouncer in transaction-pooling mode.
Create an ordinary database owner and the silo database:
The first writable gateway connects as silo_owner and runs migrations 0001–0014 in a transaction to create the silo, silo_api and silo_bucket schemas.
Start the gateway
Silo enters PostgreSQL mode when you set SILO_PG_DSN or pass a single postgres:// URI without disk arguments.
On Debian or Ubuntu with the local package, verify the checksum and install the package:
Write /etc/default/silo with your database DSN, root credentials and pool limits (replace the placeholders before starting the service):
Install the systemd drop-in /etc/systemd/system/silo.service.d/postgresql.conf so the service starts without disk arguments:
Enable and start the service, then check read and write readiness:
A healthy writable gateway returns HTTP 200 for both endpoints. See Configuration for all SILO_PG_* variables.
Create a bucket and user
Install mcli, trust the gateway CA, and configure an administrative alias with the root credentials:
Create the attachments bucket and an application user (app-s3):
Save a bucket-scoped policy to ~/.local/share/silo-tutorial/attachments-rw.json:
Create and attach the policy, then configure an alias (pg-app) with the app-s3 credentials:
Upload, read and delete over S3
Upload a file, list and stat the object, download it to verify the bytes, and delete it:
Write an object from SQL
The SQL transaction API (silo_api) is a Preview feature in the MVP scope.
In a psql session with permissions on silo_api and the bucket ACL relation silo_bucket.attachments, write an object inside a Read Committed transaction:
Once the transaction commits, the object is immediately visible over S3 as attachments/invoice/2026-001.txt. See Objects from SQL and the SQL API reference for grants and function signatures.
Open the Console
Open https://console.example.net:9001 in a browser that trusts the gateway CA and sign in with the root credentials. Browse Buckets → attachments → Objects to inspect or upload files, and use the IAM pages to manage users and policies.
Logical object usage in the Console differs from physical PostgreSQL table and WAL size. A physical capacity reading of Unknown is expected in PostgreSQL mode and does not indicate zero free space.
