aboutsummaryrefslogtreecommitdiff
path: root/nix/flake
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2025-07-21 08:09:23 -0700
committerFranck Cuny <franck@fcuny.net>2025-07-21 08:13:13 -0700
commit76d227f72120247640559e96bf82b51fbab69b0e (patch)
tree266d68e61ec7ab42b154ecd4272ce11a984fb547 /nix/flake
parentimport nix profile in the server profile (diff)
downloadinfra-76d227f72120247640559e96bf82b51fbab69b0e.tar.gz
move machines definitions to top-level
Diffstat (limited to '')
-rw-r--r--nix/flake/hosts.nix16
1 files changed, 8 insertions, 8 deletions
diff --git a/nix/flake/hosts.nix b/nix/flake/hosts.nix
index 3ce8c6b..d3454bf 100644
--- a/nix/flake/hosts.nix
+++ b/nix/flake/hosts.nix
@@ -42,10 +42,10 @@ let
inherit name;
value = {
inherit system;
- hostconf = ../machines/nixos + "/${system}/${filename}";
+ hostconf = "${self}/machines/nixos/${system}/${filename}";
};
}
- ) (builtins.readDir ../machines/nixos/${system}))
+ ) (builtins.readDir "${self}/machines/nixos/${system}"))
) { };
mapMacs = foldl' (
@@ -60,10 +60,10 @@ let
inherit name;
value = {
inherit system;
- hostconf = ../machines/darwin + "/${system}/${filename}";
+ hostconf = "${self}/machines/darwin/${system}/${filename}";
};
}
- ) (builtins.readDir ../machines/darwin/${system}))
+ ) (builtins.readDir "${self}/machines/darwin/${system}"))
) { };
defaultModules = [
@@ -71,14 +71,14 @@ let
inputs.agenix.nixosModules.age
inputs.disko.nixosModules.disko
inputs.home-manager.nixosModules.home-manager
- ../modules/default.nix
+ "${self}/nix/modules/default.nix"
];
darwinDefaultModules = [
nixSettings
inputs.agenix.darwinModules.age
inputs.home-manager.darwinModules.home-manager
- ../modules/default-darwin.nix
+ "${self}/nix/modules/default-darwin.nix"
];
darwinConfigurations = mapAttrs' (
@@ -124,7 +124,7 @@ let
}
);
}
- ) (mapMacs (mapSystems ../machines/darwin));
+ ) (mapMacs (mapSystems "${self}/machines/darwin"));
nixosConfigurations = mapAttrs' (
name: conf:
@@ -175,7 +175,7 @@ let
}
);
}
- ) (mapHosts (mapSystems ../machines/nixos));
+ ) (mapHosts (mapSystems "${self}/machines/nixos"));
in
{
flake = {