Blog Posts

  • When Imperfect Systems are Good, Actually: Bluesky's Lossy Timelines

    I love reading technical deep-dives in to system design and scaling. This post from Jaz (infrastructure at Bluesky) is a great read on how they balanced user needs with performance by finding where they could be โ€˜imperfectโ€™.

    By specifying the limits of reasonable user behavior and embracing imperfection for users who go beyond it, we can continue to provide service that meets the expectations of users without sacrificing scalability of the system.

    Thereโ€™s always sacrifices to be made in system design - I like the idea of defining a โ€˜reasonable limitโ€™ for any one user and building optimisations around that limit.

  • Minimal GitOps-like Deployment Tool

    If you have more than 1 server and a need to deploy multiple applications 'somewhere' on that cluster without having to micromanage - don't reinvent the wheel, just use Kubernetes. It's the industry standard for a reason, and you're not going to have a hard time finding help when you need it.

    However, it's easy to forget that there's a class of service/business where this doesn't make sense. Many small businesses (if they're not using a PaaS like Fly), don't have the resources to run a Kubernetes cluster and 95% of the time, just need an app to run on a single VPS.

    Read more โ†’

  • Django on Fly.io with Litestream/LiteFS

    I've been playing with Fly.io a lot recently (see my series on deploying Wagtail to Fly.io).

    One of the neat things that has come out of Fly is a renewed interest across the dev world in SQLite - an embedded database that doesn't need any special servers or delicate configuration.

    Some part of this interest comes from the thought that if you had an SQLite database that sat right next to your application, in the same VM, with no network latency, that's probably going to be pretty quick and pretty easy to deploy.

    Read more โ†’

  • Deploying a Wagtail site to Fly.io Part 1: The Plan

    I've been playing with Fly.io quite a bit recently.

    Yes I'm drawn to the exciting tech, the fascinating blog posts, the attractive pricing and generous free tier (for now...), but more importantly, Fly are one of the few new breed 'PaaS' tools that realise what Heroku got right with its excellent developer experience, and are on a fast-track to replicating and eventually exceeding what Heroku offers.

    While Fly is quickly establishing itself as my go-to hosting platform for personal/hobby projects (even before the "sunsetting" of Heroku's free tier), Wagtail has been my go-to platform for almost all the sites I build for quite a while.

    Read more โ†’

  • Deploying a Wagtail site to Fly.io Part 3: Dockerising & Requirements

    For Fly to know how to run our application, we need to package it up in a way that it understands. We need to tell it things like:

    • How to acquire all our project's dependencies
    • What application server to use and how to configure it
    • What files need to be made available to the platform

    Fly currently supports 3 ways of doing this; Dockerfiles, Buildpacks and Nixpacks. The latter two are a great way to get started if you're not familiar with Docker - they provide a pre-built way for the platform to build and run your application without the developer having to do much extra work.

    Read more โ†’

  • Deploying a Wagtail site to Fly.io Part 4: Static & Media Files

    Our Wagtail app needs to serve two different 'categories' of files:

    • Static files - things that are in our codebase like CSS and JS and don't change unless we deploy a new version of the site.
    • Media files - images and documents uploaded by our site users and content editors.

    We'll use a couple of very useful Django packages to handle these.

    Read more โ†’

  • Make Your Webcam Look Slightly More Professional (mainly on Linux)

    (alternate title: Overcomplicating Things That Aren't That Important)

    Being annoyed with Zoom's lack of smart-background blurring on Linux led me down a rabbit-hole out of which I have only just emerged, covered in who-knows-what and left with a sense that I should probably have left the poor rabbits alone.

    Do you want to make this questionably improved transformation to your cheap webcam:

    Read more โ†’

  • Exposing Home Assistant using Cloudflare Tunnel

    I use the wonderful Home Assistant on our home network for a variety of weird and wonderful automations and as a nice dashboard to all the devices in our home.

    Nothing on my home network can be reached from the outside world without a VPN. Unfortunately, that presents a few issues with Home Assistant:

    • Accessing the Home Assistant UI from out-and-about is a pain.
    • The Home Assistant app can't report useful information such as location data unless the device is connected to the VPN.
    • There are a number of integrations which use webhooks or similar to communicate data to your HA instance.

    So far, I've been living with these problems. Exposing my entire HA instance to the world isn't something I'm comfortable with.

    Read more โ†’

Have a topic in mind?

If there's something you'd like me to write about, feel free to reach out!

Contact Me