Running SQLite Apps on Docker and Kubernetes with Litestream

Summary
OpenRun has integrated Litestream into its open-source GitOps platform, enabling continuous replication of SQLite databases to AWS S3 or compatible storage like Cloudflare R2. The platform automatically restores databases when app volumes are empty or recreated, removing the need for developers to install Litestream or manage object storage. This feature works on Docker, Podman, and Kubernetes, allowing developers to use SQLite normally without modifying their container images or implementing restore logic. The setup is defined once in the server configuration, and OpenRun handles replication and restoration outside the app container. The same configuration applies to single-node setups and Kubernetes clusters, with the platform adding a restore init container and Litestream sidecar on Kubernetes 1.29 or newer.
Key points
- Replication targets include AWS S3, Cloudflare R2, MinIO, and SeaweedFS.
- Restoration is automatic when OpenRun detects an empty or recreated app volume.
- On Kubernetes, OpenRun adds a restore init container and a native Litestream sidecar.
- Apps with a SQLite binding run as a single replica with the Recreate update strategy.
- A sudden crash can lose roughly the most recent second of writes under normal conditions.
Timeline
OpenRun announces built-in Litestream support for SQLite apps.
“The app image stays unchanged, and new SQLite apps can use replication without any Litestream-specific setup.”
Background
SQLite is a file-backed database ideal for internal tools and small web apps, but without platform integration, users must deploy and configure Litestream alongside the app.
Why it matters
This integration moves the operational burden of replication and restoration into the platform, enabling developers to use SQLite with built-in durability and point-in-time recovery.
What's next
The replication is asynchronous with a default one-second sync interval, and the node-loss recovery scenario is exercised in CI tests.