-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
151 lines (136 loc) · 4.13 KB
/
Copy pathflake.nix
File metadata and controls
151 lines (136 loc) · 4.13 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
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
149
150
151
{
# Add binary caches
nixConfig = {
extra-substituters = [ "https://noctalia.cachix.org" ];
extra-trusted-public-keys = [ "noctalia.cachix.org-1:pCOR47nnMEo5thcxNDtzWpOxNFQsBRglJzxWPp3dkU4=" ];
};
inputs = {
# Use nixos-unstable by default
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
# Nixpkgs master
nixpkgs-master.url = "github:nixos/nixpkgs/master";
# Stable nixpkgs
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-24.11";
# Secure boot
lanzaboote = {
url = "github:nix-community/lanzaboote/v1.1.0";
inputs.nixpkgs.follows = "nixpkgs";
};
# 'Vaporise'
vaporise.url = "github:devraza/vaporise";
# Home manager
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
# Wayland compositor
hyprland.url = "github:hyprwm/Hyprland/main";
split-monitor-workspaces = {
url = "github:zjeffer/split-monitor-workspaces";
inputs.hyprland.follows = "hyprland";
};
# System shell
noctalia = {
url = "github:noctalia-dev/noctalia/legacy-v4";
inputs.nixpkgs.follows = "nixpkgs";
};
# For the CachyOS kernel
nix-cachyos-kernel.url = "github:xddxdd/nix-cachyos-kernel/release";
};
outputs =
{
self,
nixpkgs,
nixpkgs-stable,
nixpkgs-master,
nixos-hardware,
lanzaboote,
vaporise,
nix-cachyos-kernel,
home-manager,
...
}@inputs:
{
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt; # nix fmt
# Executed by `nix build .#<name>`
nixosConfigurations = {
# Frigidflash nix/home configuration
frigidflash = nixpkgs.lib.nixosSystem rec {
system = "x86_64-linux";
specialArgs = {
pkgs-stable = import nixpkgs-stable {
inherit system;
config.allowUnfree = true;
};
inherit inputs;
};
modules = [
./hosts/frigidflash
./hosts/workstations.nix
./hosts/cachy.nix
(
{
config,
pkgs,
lib,
...
}:
{
environment.systemPackages = [
pkgs.sbctl
];
boot.loader.systemd-boot.enable = lib.mkForce false;
boot.lanzaboote = {
enable = true;
pkiBundle = "/var/lib/sbctl";
};
}
)
lanzaboote.nixosModules.lanzaboote # secure boot
nixos-hardware.nixosModules.lenovo-thinkpad-p14s-amd-gen5 # preset
home-manager.nixosModules.home-manager
(
{ config, ... }:
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.devraza = import ./home;
home-manager.extraSpecialArgs = {
pkgs-stable = import nixpkgs-stable {
inherit system;
config.allowUnfree = true;
};
pkgs-master = import nixpkgs-master { inherit system; };
inherit inputs;
};
}
)
];
};
# Cryogenesis nix/home configuration
cryogenesis = nixpkgs.lib.nixosSystem rec {
system = "x86_64-linux";
specialArgs = {
inherit inputs;
pkgs-stable = import nixpkgs-stable { inherit system; };
};
modules = [
./hosts/cryogenesis
./hosts/cachy.nix
home-manager.nixosModules.home-manager
(
{ config, ... }:
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.devraza = import ./home/cryogenesis;
home-manager.extraSpecialArgs = {
inherit inputs;
};
}
)
];
};
};
};
}