Skip to content

Commit

Permalink
🔧 (flake): nixosSystem refact
Browse files Browse the repository at this point in the history
  • Loading branch information
elythh committed Oct 10, 2024
1 parent 762ed5c commit ddd35f2
Showing 1 changed file with 18 additions and 22 deletions.
40 changes: 18 additions & 22 deletions hosts/default.nix
Original file line number Diff line number Diff line change
@@ -1,28 +1,24 @@
{ self, inputs, ... }:
{
flake = {
nixosConfigurations =
let
inherit (inputs.nixpkgs.lib) nixosSystem;
inherit (import "${self}/modules/nixos") default;
flake.nixosConfigurations =
let
inherit (inputs.nixpkgs.lib) nixosSystem;
inherit (import "${self}/modules/nixos") default;

specialArgs = {
inherit inputs self;
};
in
{
grovetender = nixosSystem {
inherit specialArgs;
modules = default ++ [ ./grovetender ];
};
aurelionite = nixosSystem {
inherit specialArgs;
modules = default ++ [ ./aurelionite ];
};
mithrix = nixosSystem {
specialArgs = {
inherit inputs self;
};

mkHost =
hostname:
nixosSystem {
inherit specialArgs;
modules = default ++ [ ./mithrix ];
modules = default ++ [ ./${hostname} ];
};
};
};
in
{
grovetender = mkHost "grovetender";
aurelionite = mkHost "aurelionite";
mithrix = mkHost "mithrix";
};
}

0 comments on commit ddd35f2

Please sign in to comment.