-
Notifications
You must be signed in to change notification settings - Fork 1
/
flake.nix
148 lines (143 loc) · 4.99 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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
{
nixConfig = {
extra-experimental-features = "nix-command flakes";
extra-substituters = [
"https://sarcasticadmin-systems.cachix.org"
];
extra-trusted-public-keys = [
"sarcasticadmin-systems.cachix.org-1:K6fNUgpf4HtKZLt+HoJBBNzLnt8xHm/aoKbTH2U2SfA="
];
};
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
ham-overlay = {
url = "github:sarcasticadmin/ham-overlay";
# Make sure to set to the specific input of the remote flake
inputs.nixpkgs.follows = "nixpkgs";
};
disko = {
url = "github:nix-community/disko/";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs =
{ self
, nixpkgs
, nixpkgs-unstable
, ham-overlay
, disko
}@inputs: {
packages.x86_64-linux =
let
pkgs = import nixpkgs {
system = "x86_64-linux";
};
in
{
dotfiles = pkgs.callPackage ./nix/pkgs/dotfiles.nix { };
};
nixosConfigurations = {
cola = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./nix/machines/_common/base.nix
./nix/machines/cola/configuration.nix
];
};
dark = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
({ config, pkgs, ... }: { nixpkgs.overlays = [ ham-overlay.overlays.default ]; })
disko.nixosModules.disko
./nix/machines/_common/users.nix
./nix/machines/_common/base.nix
./nix/machines/dark/config.nix
];
};
driver = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
./nix/machines/_common/desktop.nix
./nix/machines/_common/base.nix
./nix/machines/_common/users.nix
./nix/machines/driver/configuration.nix ];
};
mulligan = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
({ config, pkgs, ... }: { nixpkgs.overlays = [ ham-overlay.overlays.default ]; })
ham-overlay.nixosModules.default.ax25d
ham-overlay.nixosModules.default.mheardd
ham-overlay.nixosModules.default.axlistend
ham-overlay.nixosModules.default.beacond
./nix/machines/_common/base.nix
./nix/machines/_common/wifi.nix
./nix/machines/mulligan/configuration.nix
];
};
oddball = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
disko.nixosModules.disko
({ config, pkgs, ... }: { nixpkgs.overlays = [ ham-overlay.overlays.default ]; })
ham-overlay.nixosModules.default.ax25d
ham-overlay.nixosModules.default.mheardd
ham-overlay.nixosModules.default.axlistend
ham-overlay.nixosModules.default.beacond
./nix/machines/_common/users.nix
./nix/machines/_common/base.nix
./nix/machines/_common/wifi.nix
./nix/machines/_common/desktop.nix
./nix/machines/oddball/configuration.nix
];
};
rufio = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
disko.nixosModules.disko
./nix/machines/rufio/configuration.nix
];
};
tinfoil = nixpkgs.lib.nixosSystem {
# nix build -L .#nixosConfigurations.tinfoil.config.system.build.isoImage
system = "x86_64-linux";
modules = [
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix"
./nix/isos/tinfoil/configuration.nix
];
};
simpleIso = nixpkgs.lib.nixosSystem {
# nix build -L .#nixosConfigurations.simpleIso.config.system.build.isoImage
system = "x86_64-linux";
modules = [
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix"
./nix/isos/simple/configuration.nix
];
};
sidekick = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [ ./nix/machines/sidekick/configuration.nix ];
};
sign = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [ ./nix/machines/sign/configuration.nix ];
# Example how to pass an arg to configuration.nix:
#specialArgs = { hostname = "staging"; };
};
router1 = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
disko.nixosModules.disko
#{ disko.devices.disk.disk1.device = "/dev/vda"; }
./nix/machines/router1/configuration.nix
];
specialArgs = { inherit inputs; };
};
};
};
}