From fa246cd520aa2f2b369e8cb60a926f4d3844f942 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sun, 13 Mar 2022 10:55:05 +0100 Subject: rebuild-machines: machines flake --- system-profiles/rebuild-machines/default.nix | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'system-profiles') diff --git a/system-profiles/rebuild-machines/default.nix b/system-profiles/rebuild-machines/default.nix index fe9a5f14..e434d2e4 100644 --- a/system-profiles/rebuild-machines/default.nix +++ b/system-profiles/rebuild-machines/default.nix @@ -68,7 +68,7 @@ in { }; }; }; - default = { flake.url = "git+ssh://${cfg.repoHost}/nixos?ref=flakes"; flakeOutput = hostName; }; + default = { flake = { type = "git"; url = "ssh://${cfg.repoHost}/nixos"; ref = "flakes"; } flakeOutput = hostName; }; description = '' The Flake URI of the NixOS configuration to build. ''; @@ -122,15 +122,15 @@ in { } ]; - sops.secrets = lib.mkIf (!(isNull cfg.sopsConfig)) { + sops.secrets = mkIf (!(isNull cfg.sopsConfig)) { "${cfg.sopsName}" = { sopsFile = cfg.repoPrivkey; } // cfg.sopsConfig; }; - environment.systemPackages = [ rebuildScript ]; + environment.systemPackages = [rebuildScript]; - systemd.services."rebuild-${hostName}" = lib.mkIf (cfg.period != null) { + systemd.services."rebuild-${hostName}" = mkIf (cfg.period != null) { description = "Upgrade System on Next Boot"; requisite = [ "network.target" ]; after = [ "network.target" ]; @@ -144,7 +144,7 @@ in { }; }; - systemd.timers."rebuild-${hostName}" = lib.mkIf (cfg.period != null) { + systemd.timers."rebuild-${hostName}" = mkIf (cfg.period != null) { wantedBy = [ "timers.target" ]; timerConfig = { OnCalendar = cfg.period; @@ -152,7 +152,7 @@ in { }; }; - nix.registry = lib.mkIf (cfg.flake != null) { + nix.registry = mkIf (cfg.flake != null) { ${cfg.flake.name} = { exact = false; to = cfg.flake.flake; -- cgit v1.2.3