-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
65 lines (61 loc) · 1.65 KB
/
flake.nix
File metadata and controls
65 lines (61 loc) · 1.65 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
{
description = "NixOS configuration for usdt-tracing";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.11";
disko.url = "github:nix-community/disko";
disko.inputs.nixpkgs.follows = "nixpkgs";
sops-nix.url = "github:Mic92/sops-nix";
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
};
outputs =
{
nixpkgs,
disko,
sops-nix,
...
}:
let
systems = [
"x86_64-linux"
"aarch64-linux"
];
forAllSystems = nixpkgs.lib.genAttrs systems;
settings = {
hostName = "usdt-dash";
domain = "tracing.fish.foo";
networkInterface = "enp1s0";
ipAddress = "188.245.67.250";
prefixLength = 32;
gateway = "172.31.1.1";
sshKeys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH988C5DbEPHfoCphoW23MWq9M6fmA4UTXREiZU0J7n0 will.hetzner@temp.com"
];
};
in
{
nixosConfigurations.default = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit settings; };
modules = [
disko.nixosModules.disko
sops-nix.nixosModules.sops
./disk-config.nix
./hardware-configuration.nix
./configuration.nix
];
};
devShells = forAllSystems (system: {
default = nixpkgs.legacyPackages.${system}.mkShell {
packages = with nixpkgs.legacyPackages.${system}; [
just
sops
age
ssh-to-age
nixos-anywhere
nixfmt-tree
];
};
});
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.nixfmt-tree);
};
}