WIP: migrate to using builders flake module
This commit is contained in:
parent
5e550368b1
commit
a8e19d23b4
2 changed files with 29 additions and 21 deletions
47
flake.nix
47
flake.nix
|
@ -30,25 +30,36 @@
|
|||
|
||||
outputs = inputs@{ flake-parts, deploy-rs, nixpkgs, self, ... }:
|
||||
flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
# imports = [ ./flakeModules/builders.nix ];
|
||||
#
|
||||
imports = [ ./flakeModules/builders ];
|
||||
|
||||
builders = {
|
||||
configurations.nixos = [
|
||||
{ hostname = "snowhawk"; }
|
||||
];
|
||||
|
||||
configurations.darwin = [
|
||||
{ hostname = "lynx"; }
|
||||
];
|
||||
|
||||
configurations.home = [
|
||||
{ user = "zynh"; hostname = "msiserver"; }
|
||||
{ user = "val"; hostname = "caveserver"; }
|
||||
{ user = "ravenshade"; hostname = "permafrost"; }
|
||||
];
|
||||
|
||||
nixosModules = [
|
||||
inputs.home-manager.nixosModules.default
|
||||
inputs.chaotic.nixosModules.default
|
||||
inputs.niri.nixosModules.niri
|
||||
];
|
||||
|
||||
homeModules = [
|
||||
inputs.chaotic.homeManagerModules.default
|
||||
];
|
||||
};
|
||||
|
||||
flake =
|
||||
let builders = import ./builders.nix inputs;
|
||||
in {
|
||||
nixosConfigurations = builders.compileNixosSystems [
|
||||
{ hostname = "snowhawk"; }
|
||||
];
|
||||
|
||||
darwinConfigurations = builders.compileDarwinSystems [
|
||||
{ hostname = "lynx"; }
|
||||
];
|
||||
|
||||
homeConfigurations = builders.compileHomes [
|
||||
{ user = "zynh"; hostname = "msiserver"; }
|
||||
{ user = "val"; hostname = "caveserver"; }
|
||||
{ user = "ravenshade"; hostname = "permafrost"; }
|
||||
];
|
||||
|
||||
{
|
||||
deploy =
|
||||
let homeConfigPath = username: deploy-rs.lib.x86_64-linux.activate.home-manager self.homeConfigurations.${username};
|
||||
in {
|
||||
|
|
|
@ -75,8 +75,6 @@ rec {
|
|||
./hosts/${hostname}/hardware-configuration.nix
|
||||
./hosts/${hostname}/configuration.nix
|
||||
inputs.home-manager.nixosModules.default
|
||||
inputs.chaotic.nixosModules.default
|
||||
inputs.niri.nixosModules.niri
|
||||
{
|
||||
home-manager.extraSpecialArgs = {
|
||||
inherit inputs self pkgs;
|
||||
|
@ -100,7 +98,6 @@ rec {
|
|||
extraSpecialArgs = { inherit inputs self; };
|
||||
|
||||
modules = [
|
||||
inputs.chaotic.homeManagerModules.default
|
||||
./hosts/${configHost}/home.nix
|
||||
];
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue