System Persistence Leaf
cells/persist/system.nix declares the system state that survives an impermanent root.
Up: impermanence and persistence Down: SOPS secrets
What this leaf does
It persists selected /etc and /var state, machine identity, and directories needed for users, password files, and SOPS age keys.
environment.persistence."/persist" = {
directories = [
"/etc/ssh"
"/var/log"
"/var/lib/systemd"
];
files = [
"/etc/machine-id"
];
};Why it exists
With tmpfs root, unmanaged state disappears on reboot. This leaf says exactly which operating-system state is allowed to remain.
Secret storage
The real config creates a persistent age key path for sops-nix. Public docs should show the pattern without exposing actual machine-specific key material.