-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
106 lines (97 loc) · 2.99 KB
/
flake.nix
File metadata and controls
106 lines (97 loc) · 2.99 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
{
description = "NixOS: fintohaps";
inputs = {
# Official NixOS package source
nixpkgs.url = "github:NixOS/nixpkgs/release-25.11";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
# home-manager, used for managing user configuration
home-manager = {
# url = "git+https://github.com/lorenzleutgeb/home-manager.git?rev=4a0213a852c4c8100b706cae04ea54dbe1e8f956";
url = "github:nix-community/home-manager/release-25.11";
inputs.nixpkgs.follows = "nixpkgs";
};
nur.url = "github:nix-community/NUR";
microvm = {
url = "github:microvm-nix/microvm.nix";
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
opencode.url = "github:dan-online/opencode-nix";
llm-agents.url = "github:numtide/llm-agents.nix";
};
nixConfig = {
extra-substituters = [
"https://nix-community.cachix.org"
"https://cache.numtide.com"
];
extra-trusted-public-keys = [
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"niks3.numtide.com-1:DTx8wZduET09hRmMtKdQDxNNthLQETkc/yaX7M4qK0g="
];
};
outputs = {
self,
nixpkgs,
home-manager,
nur,
microvm,
sops-nix,
...
} @ inputs: let
pkgs = import nixpkgs {
system = "x86_64-linux";
};
unstable = import inputs.nixpkgs-unstable {system = "x86_64-linux";};
nurNoPkgs = import nur {nurpkgs = pkgs;};
registryModule = [
{
nix.registry.nixpkgs.flake = inputs.nixpkgs;
# register this flake in the registry so we can refer to it as
# fintos
nix.registry.fintos.flake = inputs.self;
}
];
in {
# Formatter
formatter.x86_64-linux = pkgs.alejandra;
nixosConfigurations = {
# To deploy this NixOS system (from any directory):
# sudo nixos-rebuild switch --flake fintos
"haptop" = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs nurNoPkgs;};
modules =
[
./configuration.nix
./modules/nixos/gnome.nix
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.fintohaps = ./home.nix;
# Optionally, use home-manager.extraSpecialArgs to pass
# arguments to home.nix
home-manager.extraSpecialArgs = {
inherit nurNoPkgs;
inherit unstable;
inherit inputs;
};
}
{
nixpkgs.overlays = [
(import ./overlays/radicle-node.nix)
(import ./overlays/pi-packages.nix)
inputs.opencode.overlays.default
];
}
microvm.nixosModules.host
./microvm/network.nix
./microvm.nix
]
++ registryModule;
};
};
};
}