Two halves of one repeatable upgrade process. Neither works alone. (a) OS upgrades and reboots platform/kured/ — Kubernetes Reboot Daemon, chart 6.1.0/app 1.23.0, in its own Flux Kustomization (dependsOn platform, wait:true). NOT in platform/kustomization.yaml: that tier gates platform-config and every apps wave, so a wedged reboot daemon there could stall every application. A component added to make maintenance safer must not be able to cause an outage. infra/ansible/roles/unattended_upgrades/ — new role (node_baseline is touched by other open branches, and this is a different lifecycle), enabled for prod in group_vars. The human gate is the SENTINEL, which is how this honours node_baseline's "IT DOES NOT REBOOT" (k3s-prod-2 hung on a warm reboot 2026-09-03) and cluster-upgrade-plan.md's rejection of automating away the gate between nodes: u-u is security-only with the kernel blacklisted, so it essentially never writes /var/run/reboot-required. That file appears when an operator deliberately runs node-baseline.yml --tags kernel. kured then does only the mechanical half, including the ordering rule node_baseline has to shout. Quorum: concurrent reboots are structurally impossible, not merely unlikely. concurrency:1 plus kured's single lock annotation (API-server optimistic concurrency), and lockTtl:0 — an expiring lock is exactly the 3-node etcd catastrophe, so a hung node holds it forever and nothing cascades. Longhorn: measured 25 volumes x 3 replicas, hard anti-affinity, 600s replenishment wait, serialized rebuild — so every drain degrades ALL volumes to 2/3 and the inter-node gate must be volume robustness, not pod readiness. Doubled: lockReleaseDelay 30m (unconditional) plus kured's Prometheus alert gate (semantic). alertFilterMatchOnly:true is load-bearing — the flag inverts the regexp's meaning, and under the chart default kured would have been blocked on day one by the five alerts measured firing with no end in sight, and never rebooted anything. Kernel floor (kernel >= 6.13, EFI memattr): excluded TWICE. The running kernel comes from o=Debian Backports, which is not an allowed origin, so u-u cannot see a kernel upgrade; and ^linux- is blacklisted anyway so widening origins later cannot re-arm it. Asserted against apt-config dump, not against the file just written. 6.12 kernels are still installed and bootable on all three nodes, and nothing was held. Closes a silent no-op: update-notifier-common was absent on all three nodes, so NOTHING could create the sentinel. kured alone would have idled forever at 1/1 Running. platform/kured/alerts.yaml — three rules over kured's only metric, with a companion promtool suite pinning each both ways, plus runbooks/node-reboot-automation.md. Window is DAILY 03:00-06:00 because a weekly one forces for:8d, longer than this cluster's 7d Prometheus retention. (b) Image/dependency automation Renovate was aspirational: renovate.json present and complete, with no workflow, no in-cluster workload, and its docker+kubernetes managers disabled — so every plain image: tag was maintained by nothing while seven files claimed otherwise. .gitea/workflows/renovate.yaml — scheduled daily, dry_run default true for a safe first run, and a preflight that FAILS (not skips) without RENOVATE_TOKEN, because a skipped Gitea job reports success and that is how this stayed inert. Renovate now owns both halves; Flux image-automation is formally closed: it pushes commits rather than opening PRs (bypassing CLAUDE.md §1), and it cannot work here anyway — main is protected user_can_push:false and the flux-system GitRepository has no secretRef. Its controllers are installed and have idled 43 days with zero CRs. conformance/: +34/-0, one new SCRAPE_OWNERS entry claiming kured_. Weakens nothing; tightens the check for this component (requires service.create+metrics.create, both chart-default false, plus a companion NetworkPolicy requirement). Required because assertion (3) fails an alert over an unclaimed metric and KNOWN_UNWIRED_METRICS is shrink-only. Sensitive paths touched: clusters/**, conformance/**, .gitea/** — needs a non-author approving review; /approve-override deliberately NOT posted. NOT verified: no OS upgrade run, no node rebooted, no lock observed, the Ansible role never executed, and whether CNPG switches its primary on a drain-induced eviction (the most likely way the first real reboot fails). Full list in the handoff entry. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
35 lines
2.1 KiB
YAML
35 lines
2.1 KiB
YAML
---
|
|
# kured — namespace for the Kubernetes Reboot Daemon DaemonSet.
|
|
#
|
|
# PLATFORM INFRA, NOT AN APPLICATION NAMESPACE, and here that distinction is the difference between
|
|
# a working component and an admission rejection. kured runs `hostPID: true` with a `privileged: true`
|
|
# container (it `nsenter`s /proc/1/ns/mnt to run `/bin/systemctl reboot` on the host). Both are
|
|
# forbidden by platform/kyverno/policies/restrict-host-namespaces.yaml — but that policy, like every
|
|
# other policy in this repo, is scoped by
|
|
# `namespaceSelector: matchLabels: homelab.keithjackson.dev/app-namespace: "true"`
|
|
# and its own header states the carve-out: "platform components that do [need these] live in platform
|
|
# namespaces that do NOT carry the app-namespace label, so they are out of scope."
|
|
# Verified by reading the policies on this branch, not assumed:
|
|
# * restrict-host-namespaces.yaml rule `disallow-host-namespaces` (hostPID)
|
|
# * restrict-host-namespaces.yaml rule `disallow-privileged-containers` (privileged)
|
|
#
|
|
# We set the label EXPLICITLY to "false" rather than leaving it unset, following
|
|
# platform/intel-gpu-plugin/namespace.yaml and platform/vpn-egress: an unset label and a deliberate
|
|
# "false" are identical to the admission engine but not to a reviewer, and this component's
|
|
# correctness depends entirely on the answer.
|
|
#
|
|
# NO PodSecurity labels. There is no cluster-wide PSA baseline in this repo — `pod-security.*`
|
|
# appears only where a namespace opts IN (conformance/incluster, platform/kyverno/admission,
|
|
# platform/pm-agent), all at `enforce: restricted`. Adding them here would reject this DaemonSet for
|
|
# the same reasons Kyverno would. Leaving them off is the convention for a privileged platform
|
|
# namespace (platform/vpn-ingress/namespace.yaml sets none either).
|
|
#
|
|
# NO `gateway-access` label. kured serves no HTTP to users and attaches no HTTPRoute; its only
|
|
# listener is the :8080 metrics endpoint, reached in-cluster by Prometheus. See networkpolicy.yaml.
|
|
apiVersion: v1
|
|
kind: Namespace
|
|
metadata:
|
|
name: kured
|
|
labels:
|
|
homelab.keithjackson.dev/app-namespace: "false"
|