Files
nixos-config/hosts/m3-hermes/services
m3ta-chiron 8a083656eb fix(m3-hermes): survive corrupt hermes runtime config.yaml during activation
The hermes-agent v2026.9.24 activation snippet deep-merges Nix settings
into the runtime-writable /var/lib/hermes/.hermes/config.yaml via a bare
yaml.safe_load() with no error handling. The runtime corrupted the file
(plugin-enable appended '- moshi-hooks' at mapping-level indent), so
every nixos-rebuild switch failed with yaml.parser.ParserError inside
'hermes-agent-setup'.

- Add hermes-config-quarantine activation snippet that validates the
  YAML first and moves unparsable files aside (config.yaml.corrupt-*)
  so activation regenerates a clean config from Nix settings instead
  of blocking system updates. Wired before hermes-agent-setup via deps
  list merge; reuses the upstream merge script's python+pyyaml env.
- Declare plugins.enabled (herdr-agent-state, moshi-hooks) in Nix
  settings so plugin state survives a quarantine-and-regenerate.

Host file was repaired manually on m3-hermes (backup kept as
config.yaml.corrupt-20261004).
2026-10-04 11:09:41 +02:00
..