-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
94 lines (84 loc) · 2.46 KB
/
flake.nix
File metadata and controls
94 lines (84 loc) · 2.46 KB
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
{
description = "Nixos config flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
nixos-hardware-surface.url = "github:8bitbuddhist/nixos-hardware?ref=surface-rust-target-spec-fix";
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=v0.1.0";
nixarr = {
url = "github:rasmus-kirk/nixarr";
inputs.nixpkgs.follows = "nixpkgs-unstable";
};
nixvim = {
url = "github:nix-community/nixvim";
inputs.nixpkgs.follows = "nixpkgs-unstable";
};
};
outputs =
{
self,
nixpkgs,
nixpkgs-unstable,
nixos-hardware,
nixos-hardware-surface,
nix-flatpak,
nixarr,
nixvim,
...
}:
let
modulesForAllSystems = [
nixvim.nixosModules.nixvim
];
distributeInputs = {
util = import ./util.nix nixpkgs.lib;
secrets = builtins.fromJSON (builtins.readFile "${self}/secrets/secrets.json");
hosts = builtins.fromJSON (builtins.readFile "${self}/secrets/hosts.json");
builders = builtins.fromJSON (builtins.readFile "${self}/system/builders.json");
inherit nix-flatpak;
inherit nixarr;
};
systemMake =
{
module-paths ? [ ],
}:
nixpkgs-unstable.lib.nixosSystem {
specialArgs = distributeInputs;
modules = module-paths ++ modulesForAllSystems;
};
in
{
nixosConfigurations = {
nixarf = systemMake {
module-paths = [ ./hosts/nixarf ];
};
nst-van-checkout-surface = systemMake {
module-paths = [
./hosts/nst-van-checkout-surface
nixos-hardware-surface.nixosModules.microsoft-surface-pro-intel
];
};
snootflix = systemMake {
module-paths = [
./hosts/snootflix2
nixarr.nixosModules.default
];
};
nst-van-checkout = systemMake {
module-paths = [
./hosts/nst-van-checkout
nixos-hardware.nixosModules.common-cpu-intel
nixos-hardware.nixosModules.common-pc-laptop-ssd
];
};
nixpad = systemMake {
module-paths = [
./hosts/nixpad
nixos-hardware.nixosModules.lenovo-thinkpad-l13
nix-flatpak.nixosModules.nix-flatpak
];
};
};
};
}