From a9b1f9b419e4db9732a1ec5eef9dcead5a8f183d Mon Sep 17 00:00:00 2001 From: tdback Date: Sun, 26 Jan 2025 11:36:10 -0500 Subject: flake: overhaul on flake, added deploy-rs --- modules/default.nix | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'modules') diff --git a/modules/default.nix b/modules/default.nix index 49f08c5..91ab291 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -6,8 +6,17 @@ let mkModules = moduleAttrList: builtins.concatMap (moduleAttr: genModules moduleAttr) moduleAttrList; in { - mkSystem = hostname: system: nixpkgsVersion: modules: { - ${hostname} = nixpkgsVersion.lib.nixosSystem { + mkSystem = hostname: system: nixpkgsVersion: modules: rec { + deploy.nodes.${hostname} = { + inherit hostname; + profiles.system = { + user = "root"; + sshUser = "tdback"; + path = inputs.deploy-rs.lib.${system}.activate.nixos nixosConfigurations.${hostname}; + }; + }; + + nixosConfigurations.${hostname} = nixpkgsVersion.lib.nixosSystem { inherit system; modules = (mkModules modules) ++ [ "${inputs.self}/hosts/${hostname}" -- cgit v1.2.3