-
Notifications
You must be signed in to change notification settings - Fork 1
/
flake.nix
74 lines (65 loc) · 1.69 KB
/
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
{
description = "NixOS, macOS and WSL system configuration";
inputs = {
nixpkgs = {
url = "github:NixOS/nixpkgs/master";
};
nix-darwin = {
url = "github:LnL7/nix-darwin/master";
inputs.nixpkgs.follows = "nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager/master";
inputs.nixpkgs.follows = "nixpkgs";
};
secrets = {
url = "git+ssh://[email protected]/leonbreedt/secrets.git";
flake = false;
};
nixos-wsl = {
url = "github:nix-community/nixos-wsl";
};
};
outputs = {nixpkgs, nix-darwin, secrets, ...}@inputs:
let
lib = import ./lib {
inherit inputs;
inherit (nixpkgs) lib;
};
in
{
darwinConfigurations = {
athena = lib.mkDarwin {
hostname = "athena";
user = "leon";
};
KHW90GQLQF = lib.mkDarwin {
hostname = "KHW90GQLQF";
user = "i070279";
isPersonal = false;
};
};
nixosConfigurations = {
galactica-wsl = lib.mkWsl {
hostname = "galactica";
user = "leon";
};
galactica = lib.mkNixos {
hostname = "galactica";
user = "leon";
useX11 = true;
useGnome = true;
tarsnapBackups = true;
};
starbuck = lib.mkNixos {
hostname = "starbuck";
user = "leon";
isUnifiController = true;
tarsnapBackups = true;
tarsnapDirs = [ "/etc" "/root" "/var/lib/unifi/data/sites" "/var/lib/unifi/data/backup" ];
tarsnapHealthCheckUUID = builtins.readFile "${secrets}/personal-controller-tarsnap-hc-uuid";
tarsnapKey = builtins.readFile "${secrets}/tarsnap-starbuck-key";
};
};
};
}