-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
119 lines (113 loc) · 3.25 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
rec {
description = "Description for the project";
nixConfig = {
extra-substituters = [
"https://cache.garnix.io"
"https://cache.lix.systems"
"https://deploy-rs.cachix.org"
"https://nix-community.cachix.org"
];
extra-trusted-public-keys = [
"cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
"cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o="
"deploy-rs.cachix.org-1:xfNobmiwF/vzvK1gpfediPwpdIP0rpDV2rYqx40zdSI="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
];
builders-use-substitutes = true;
connect-timeout = 25;
warn-dirty = false;
};
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs-stable.url = "github:nixos/nixpkgs";
deploy-rs = {
url = "github:serokell/deploy-rs";
inputs.nixpkgs.follows = "nixpkgs";
};
disko = {
url = "github:nix-community/disko";
inputs.nixpkgs.follows = "nixpkgs";
};
flake-parts = {
url = "github:hercules-ci/flake-parts";
};
ghostty = {
url = "github:ghostty-org/ghostty";
inputs.nixpkgs-stable.follows = "nixpkgs-stable";
inputs.nixpkgs-unstable.follows = "nixpkgs";
};
git-hooks = {
url = "github:cachix/git-hooks.nix";
inputs.nixpkgs.follows = "nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
impermanence = {
url = "github:nix-community/impermanence";
};
krewfile = {
url = "github:brumhard/krewfile";
inputs.nixpkgs.follows = "nixpkgs";
};
lix = {
url = "git+https://git.lix.systems/lix-project/lix?ref=main";
};
lix-module = {
url = "git+https://git.lix.systems/lix-project/nixos-module?ref=main";
inputs.lix.follows = "lix";
};
nix-index-database = {
url = "github:nix-community/nix-index-database";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-anywhere = {
url = "github:nix-community/nixos-anywhere";
inputs.nixpkgs.follows = "nixpkgs";
inputs.nixos-stable.follows = "nixpkgs-stable";
};
nixos-hardware = {
url = "github:NixOS/nixos-hardware/master";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
stylix = {
url = "github:danth/stylix";
inputs.nixpkgs.follows = "nixpkgs";
inputs.home-manager.follows = "home-manager";
};
};
outputs =
inputs@{ flake-parts, ... }:
let
# https://nixos.zulipchat.com/#narrow/stream/419910-flake-parts/topic/Overriding.20.60lib.60.20in.20flake-parts
specialArgs = {
inherit nixConfig;
lib = inputs.nixpkgs.lib.extend (_: _: (import ./lib { inherit inputs nixConfig; }));
};
in
flake-parts.lib.mkFlake { inherit inputs specialArgs; } {
systems = [
"x86_64-linux"
"aarch64-linux"
"aarch64-darwin"
"x86_64-darwin"
];
imports = [
./local
./machines
];
}
// {
nixlab = {
system = ./modules/system;
hardware = {
incus = ./modules/hardware/incus.nix;
ms-01 = ./modules/hardware/ms-01.nix;
};
};
};
}