nixos/nncp: recursively merge configurations

This commit is contained in:
Emery Hemingway 2024-11-21 11:06:22 +00:00
parent 2e9c42e1c8
commit 50bbfb5788

View File

@ -79,7 +79,7 @@ in {
for f in ${jsonCfgFile} ${builtins.toString config.programs.nncp.secrets}
do
${lib.getExe pkgs.hjson-go} -c <"$f"
done |${lib.getExe pkgs.jq} --slurp add >${nncpCfgFile}
done |${lib.getExe pkgs.jq} --slurp 'reduce .[] as $x ({}; . * $x)' >${nncpCfgFile}
chgrp ${programCfg.group} ${nncpCfgFile}
'';
};