-
Notifications
You must be signed in to change notification settings - Fork 3
/
flake.nix
29 lines (27 loc) · 812 Bytes
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
{
description = "My personal laptop configuration with Nix";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = inputs@{ self, nixpkgs, home-manager, ... }:
let
mkMachine = hostName: machine: nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = inputs // { inherit hostName; };
modules = [
./configuration.nix
machine
home-manager.nixosModule
];
};
in {
nixosConfigurations = {
"Jan-Laptop" = mkMachine "Jan-Laptop" ./machines/laptop.nix;
"hwlap0036-macs" = mkMachine "hwlap0036-macs" ./machines/university-laptop.nix;
};
};
}