Litestream single-node deployments with attached volumes

Hello! I’m building a small Go app with SQLite and am interested in using Litestream for backing up to Backblaze B2. I expect that a single app/machine will be more than sufficient for my use case, I’m not intending to scale it up.

My understanding is that LiteFS is the intended future for live replication, I’m interested just in the single-node disaster recovery of Litestream.

The Litestream docs indicate possible data corruption if more than one application is writing to the same bucket with the same path:

How does this interact with a Fly.io deployment process that starts up a new container and waits for a successful health check before stopping the old container? Both containers would be live for at least a few seconds.

I’m also intending to mount a persistent volume to hold the SQLite database, but I understand that volumes cannot be mounted to more than one machine at a time.

I did find on these forums that the official “blue green” deployments do not support volumes at this time. What does a non-blue-green (blue blue?) deployment look like in my scenario? Does the old machine stop first, then the new one starts? Is there a gap where network connections will receive 500 (503?) errors during the switchover, or does the Fly proxy keep connections open until the new container is ready?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.