Until the middle of November, every deploy of my own code on my homelab waited on me, most of them as a command I pasted into a terminal myself, one-line fixes to services with full test suites included. My deploy process waits a minute between commands, so I can see each container come back healthy instead of stuck in a boot loop. The services also lean on each other’s volumes, networks and agents, which meant one change often took several pastes back to back. At the end of them I was where I had started, as far as anyone using the house could tell. Security or reliability often came out a little ahead. I had spent the time to get back to baseline.
The pastes also queued. Small services get modified in the course of larger projects, or hit a corner case that needs a fix, and each of those became an item in my to-do tracker that waited on me twice: first to read the notification and learn I was needed, then to do the paste. I was the bottleneck on work that was already built, tested and merged.
The short way out was to give my AI coding sessions deploy rights on the server. I turned that down. Models struggle with the gray area where a thing is fine here and the same thing is not fine over there, and I did not want anything that held deploy rights to deploy past me and then extend those rights to every other container.
The option I took keeps the authority where it already lived. Patchday, the service that applies my weekly container updates, already had a part that polls for new commits, health-checks a deploy and rolls it back. Since November 17 it also reads a list of which services may deploy themselves. The list is a file on the server owned by root, the administrator account, outside what Patchday is set up to write. The services named in it cannot edit it or point the process at a file of their own, and no session gained a credential. It works like a hall pass: a service deploys on its own only if its name is on the list, and a name goes on it only when I put it there. Patchday was built to take unattended changes out of the house, so this is a deliberate step the other way, for a named list.
A service on that list is tier A. Today the list names Mailroom, my Gmail triage agent, along with the morning brief, the health coach and a few smaller services. When one of them changes, Patchday builds a candidate image and runs the service’s test suite against it in a sandbox. If the suite passes, it switches the service over, runs the health checks, and rolls back to the previous image when they fail. The candidate never touches the live image tag until its tests have passed, so a failed test leaves nothing to undo. By design I hear nothing when it works. A failure that rolled back sends one card to the Inbox in Dispatch, my phone app.
Tier B asks first, with a Deploy or Not now question in that same Inbox. Anything not on the list lands there, and two services stay there on purpose: Pepper, my chief-of-staff agent, and Scout, which proposes posts for this blog. Tier C is still a paste: data services such as Immich, the family photo library, and Paperless, my document archive, and anything that needs surgery on the compose files. That last group is the one that would affect my family or the core of the homelab (data storage, photo backup), and it will always go through me, with a close read of the release notes and a readiness to roll back at the first sign of trouble. I built that path to move with precision over everything else. The trouble was that services which have run themselves since I created them were stuck at the pace of the most delicate ones.
Before a repo went live, it spent three days in shadow: Patchday ran every step up to the switch-over, logged what it would have deployed, and then asked me as if the service were tier B. Shadow has a blind spot. Some of the checks Patchday runs on a deploy come after the switch-over, against the running service, and shadow never gets that far. On November 19, a coding session ran each tier A service’s checks exactly as Patchday would and found five that could never have passed. Left in place, the ones after the switch-over would have rolled back every deploy that reached them. The fixes went into Patchday the same day. One of the five, a trial run of the health coach that refuses to start without a date, was removed instead of fixed.
The arrangement is days old and has no track record yet. It also does nothing to contain Patchday, which holds the Docker socket and could deploy anything before the file existed. What the file settles is which services Patchday will deploy without asking me. Everything off the list still waits for my tap or my paste, and so do the weekly image updates.
The open question is where that line goes. On November 20 I ruled one more onto the list: the dead-letter job for Mailroom. It is a small daily job that asks me in the Inbox about package-tracking numbers that failed to process. It has no Gmail access, and the one credential it carries can only post questions. Leaving it off would have turned every Mailroom merge into a tap for me. On paper I am comfortable with the grants I have made, and I can see adding several more over time. I also know that trading security for convenience is always a losing bet, so the grants come with a condition: any service that rolls back gets its tier looked at again.