71 lines
1.4 KiB
Nix
71 lines
1.4 KiB
Nix
{
|
|
description = "My System Configs";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "nixpkgs/nixos-unstable";
|
|
|
|
i3utils.url = "git+file:///home/daniel/go/src/i3utils";
|
|
|
|
home-manager.url = "github:nix-community/home-manager/master";
|
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
outputs = { nixpkgs, home-manager, i3utils, ... }:
|
|
let
|
|
system = "x86_64-linux";
|
|
|
|
pkgs = import nixpkgs {
|
|
inherit system;
|
|
|
|
config = {
|
|
allowUnfree = true;
|
|
};
|
|
};
|
|
|
|
lib = nixpkgs.lib;
|
|
|
|
hostSystem = { hostname }: lib.nixosSystem {
|
|
inherit system;
|
|
|
|
modules = [
|
|
./hosts/${hostname}/configuration.nix
|
|
({ pkgs, ... }: {
|
|
nixpkgs.overlays = [ i3utils.overlay ];
|
|
})
|
|
];
|
|
};
|
|
|
|
mkUserConf = { hostname, extraSauce ? [] }:
|
|
home-manager.lib.homeManagerConfiguration {
|
|
inherit system pkgs;
|
|
|
|
username = "daniel";
|
|
homeDirectory = "/home/daniel";
|
|
configuration = {
|
|
imports = [
|
|
./user/daniel/home.nix
|
|
({ pkgs, ... }: {
|
|
nixpkgs.overlays = [ i3utils.overlay ];
|
|
})
|
|
] ++ extraSauce;
|
|
};
|
|
stateVersion = "21.05";
|
|
};
|
|
|
|
|
|
in {
|
|
homeConfigurations = {
|
|
daniel-dingbox = mkUserConf { hostname = "dingbox"; };
|
|
daniel-miniding = mkUserConf {
|
|
hostname = "miniding";
|
|
extraSauce = [ ./user/host-specific/miniding ];
|
|
};
|
|
};
|
|
|
|
nixosConfigurations = {
|
|
dingbox = hostSystem { hostname = "dingbox"; };
|
|
miniding = hostSystem { hostname = "miniding"; };
|
|
};
|
|
};
|
|
}
|