Merge pull request 'Set networking.hostName to clanCore.machineName' (#1140) from networkd into main
Some checks failed
checks / check-links (push) Failing after 13s
checks / checks (push) Successful in 39s
checks / checks-impure (push) Successful in 1m50s

This commit is contained in:
clan-bot 2024-04-09 13:14:44 +00:00
commit 5dac575be8
2 changed files with 2 additions and 1 deletions

View File

@ -58,6 +58,7 @@ let
(machines.${name} or { })
(
{
networking.hostName = lib.mkDefault name;
clanCore.clanName = clanName;
clanCore.clanIcon = clanIcon;
clanCore.clanDir = directory;

View File

@ -46,7 +46,7 @@ in
clanCore.facts.secretModule = "clan_cli.facts.secret_modules.sops";
clanCore.facts.secretUploadDirectory = lib.mkDefault "/var/lib/sops-nix";
sops.secrets = builtins.mapAttrs (name: _: {
name = lib.strings.removePrefix "${config.networking.hostName}-" name;
name = lib.strings.removePrefix "${config.clanCore.machineName}-" name;
sopsFile = config.clanCore.clanDir + "/sops/secrets/${name}/secret";
format = "binary";
}) secrets;