Files
hermenix/guest
ari e99744f628 guest: rm -rf /etc/nixos before symlinking it to the state disk
/etc/nixos is a real directory by default on NixOS. ln -sfn only replaces
an existing LINKNAME in place when it's already a symlink; against a plain
directory it instead creates the link *inside* it, leaving /etc/nixos
itself untouched. Confirmed live: /etc/nixos/nixos -> /var/lib/hermes/nixos
existed while /etc/nixos itself stayed a stray empty directory, so
`nix flake lock /etc/nixos` couldn't find a flake.nix. rm -rf first makes
this idempotent regardless of what currently occupies the path.
2026-09-16 12:00:13 -04:00
..