blob: 449b98f9fd02a6f4bbe86031feb64693c6584f1b (
plain)
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
|
{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05";
flake-parts.url = "github:hercules-ci/flake-parts";
nixinate.url = "github:maxaudron/nixinate";
secrets = {
url = "git+ssh://git@gitlab.com/cocainefarm/k8s/secrets";
flake = false;
};
};
outputs = inputs@{ self, nixpkgs, flake-parts, nixinate, ... }:
flake-parts.lib.mkFlake { inherit inputs; } {
imports = [ nixinate.flakeModule ./lib ];
flake =
let
system = "x86_64-linux";
specialArgs = inputs // {
nodes = self.nixosConfigurations;
};
mkSystem = modules: nixpkgs.lib.nixosSystem {
inherit specialArgs system;
modules = modules ++ [ nixinate.nixosModules.default ];
};
in
{
nixosModules = import ./modules;
nixosConfigurations = with self.nixosModules; {
# vultr-image = mkSystem [ common users image vultr ];
ettves = mkSystem [ (import ./machines/ettves) common users wireguard crypto kubernetes zfs teamspeak postgresql quassel powerdns acme authentik hydra homeassistant ];
phaenn = mkSystem [ (import ./machines/phaenn) common users wireguard crypto kubernetes zfs acme tlmp ];
fra01 = mkSystem [ (import ./machines/fra01) common users wireguard crypto kubernetes vultr bgp powerdns acme ];
nyc01 = mkSystem [ (import ./machines/nyc01) common users wireguard crypto kubernetes vultr bgp powerdns acme ];
sin01 = mkSystem [ (import ./machines/sin01) common users wireguard crypto kubernetes vultr bgp powerdns acme ];
};
};
systems = [ "x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin" ];
};
}
|