-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
97 lines (94 loc) · 2.85 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
{
description = "leona's NixOS config";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable-small";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
lix-module = {
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.91.1-1.tar.gz";
inputs.nixpkgs.follows = "nixpkgs";
};
ccc-nixlib = {
url = "gitlab:cyberchaoscreatures/nixlib/main?host=cyberchaos.dev";
inputs.nixpkgs.follows = "nixpkgs";
};
nur.url = "github:nix-community/NUR";
flake-parts.url = "github:hercules-ci/flake-parts";
home-manager = {
url = "github:nix-community/home-manager/master";
inputs.nixpkgs.follows = "nixpkgs";
};
leona-is-website = {
url = "gitlab:leona/leona.is?host=forkspace.net";
inputs.nixpkgs.follows = "nixpkgs";
};
dns = {
url = "github:kirelagin/dns.nix";
inputs.nixpkgs.follows = "nixpkgs";
};
mailserver = {
url = "gitlab:simple-nixos-mailserver/nixos-mailserver";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
colmena = {
url = "github:zhaofengli/colmena/main";
inputs.nixpkgs.follows = "nixpkgs";
};
lanzaboote = {
url = "github:nix-community/lanzaboote/master";
inputs.nixpkgs.follows = "nixpkgs";
};
disko = {
url = "github:nix-community/disko";
inputs."nixpkgs".follows = "nixpkgs";
};
darwin = {
url = "github:lnl7/nix-darwin";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } {
systems = [ "x86_64-linux" "aarch64-linux" "aarch64-darwin" ];
imports = [
./hosts
./packages
];
flake = {
overlays = {
colmena = inputs.colmena.overlay;
leona-is-website = inputs.leona-is-website.overlay;
inherit (inputs.ccc-nixlib.overlays) pleroma;
iso = final: prev: {
iso = (inputs.nixpkgs.lib.nixosSystem {
system = final.stdenv.targetPlatform.system;
specialArgs = {
inputs = inputs;
nixpkgs = inputs.nixpkgs;
};
modules = [
(import ./lib/iso.nix)
];
}).config.system.build.isoImage;
};
};
nixosModules = {
sops = import ./modules/sops;
telegraf = import ./modules/telegraf;
leona-profile = import ./users/leona/importable.nix;
};
};
perSystem = { config, pkgs, inputs', self', system, ... }: {
formatter = pkgs.nixpkgs-fmt;
devShells.default = pkgs.mkShellNoCC {
buildInputs = [
pkgs.sops
(pkgs.colmena.override { nix = pkgs.lix; })
];
};
};
};
}