← Projects

Three-node Kubernetes platform

A k3s cluster reconciled entirely from Git, with an edge, secrets and backups that are all code.

The constraints decided the design: used hardware, residential power, one operator, and no inbound ports. Anything that needs a person every week must be automated or removed, and a machine can die without losing the lab.

Three NixOS hosts form one k3s cluster with a three-member etcd quorum: a Ryzen 5 4600G platform node, an i5-7500T media node (bought for its QuickSync), and a ThinkCentre M700 Tiny that took over etcd from a 2012 MacBook. ArgoCD is the only way to change anything. OpenTofu manages the firewall and the Cloudflare Zero Trust edge, and the Cloudflare Tunnel is the only door in. External Secrets holds the credentials; Cilium runs without kube-proxy; Longhorn and CloudNativePG keep state. A staging host rehearses every datapath change first.

Backups are two daily, age-encrypted streams to Cloudflare R2 (application data kept 14 days, credentials 90). A weekly job restores and verifies them, and a separate daily check alerts when the newest copy is older than 36 hours.

GitArgoCDpullsInternetCloudflareZero Trust · OpenTofuk3s · 3 NixOS nodes3-member etcd quorumCilium, no kube-proxyExternal SecretsLonghorn · CloudNativePGchanged only through ArgoCDsynctunnelencrypted off-site backupsa weekly job verifies the copies
Everything on this diagram is declared in Git; nothing is changed by hand.
k3s · one etcd quorum · pods placed by capability label, not by host namePlatform nodeArgoCD · ingressLonghorn · NFS serversecond tunnel connectorMedia nodemedia apps · QuickSynclocal media poolonly node behind WireGuardThird etcd nodeetcd memberphoto database + Redisspare QuickSyncStaging host (not in cluster)rehearse first
What each node does. Media is single-node on purpose: a failed media node is rebuilt, not rescheduled.

NixOS · k3s · ArgoCD · OpenTofu · Cilium