August 1, 2023 by Tom Atkins ‐ 3 min read
Thanks to everyone who tried the first release of PostOwl.
Today we’re releasing some updates based on early feedback. v0.1.1 is available now from GitHub
If you’ve already got a PostOwl deployment on fly.io you can update by pulling the latest changes and redeploying. Make sure to read the notes here as you’ll need to edit some files and change your deployment command. (Future updates will be much simpler, so please bear with us for this release!)
If you already have a PostOwl deployment, follow the steps below to update. (If it’s your first time deploying, you can follow the deployment docs and ignore this section.)
git fetch --tagsthen
git checkout tags/v0.1.1(or you can
git pullif you want to get the latest changes on
.env.productionand edit the values for your site (this means we won’t need the ‘BUILD-SECRETS’ that were previously needed when deploying).
fly.toml(see the updated example in
fly.toml.example). Specifically, change line 19 to read
cmd = ["start-fly.sh"]and line 32 to read
auto_stop_machines = true
That’s it! Future deploys will just be getting the latest changes from the repo and running
‘Scale to zero’ means that when your site is inactive, the machine will automatically shutdown. This saves costs and electricity. For low traffic personal sites it’s ideal.
In the past, the problem with shutting down is that it would take some time for your site to start up again - remember the Heroku free plan?! Fly.io use firecracker vms which start almost instantly. If your site goes to sleep, you’ll hardly notice it starting up. In our tests it takes about one second for the server to respond to an http request from a cold start! 🔥
The default configuration in PostOwl has
auto_stop_machines = true in
fly.toml.example. We recommend you keep this setting. We have code that gracefully closes the database connection and shuts down the application server before the machine stops.
Now you can have the benefits of a dynamic web application without the costs of keeping a VPS up all the time. And you’re being kind to the environment! 🌳
Thanks for trying PostOwl!