network/config/default.nix

22 lines
447 B
Nix
Raw Normal View History

2022-12-20 03:47:27 +01:00
{ config, lib, ... }:
let
concatMapAttrsRecursive = with lib; f: flip pipe [ (mapAttrs f) attrValues (foldl' recursiveUpdate { }) ];
in
2021-11-13 01:23:23 +01:00
{
imports = [
2021-11-13 01:44:14 +01:00
# Secrets
2021-11-13 01:23:23 +01:00
./secrets.nix
2021-11-13 01:44:14 +01:00
# Hardware
2021-11-13 01:23:23 +01:00
./vlan.nix
2021-11-13 01:44:14 +01:00
./switch.nix
./ap.nix
./server.nix
2022-12-20 03:47:27 +01:00
]
2021-11-15 21:24:44 +01:00
# IP networks
2022-12-20 03:47:27 +01:00
++ lib.filesystem.listFilesRecursive ./net;
site.net-combined = concatMapAttrsRecursive (name: value: { inherit (value) hosts4 hosts6; }) config.site.net;
2021-11-13 01:23:23 +01:00
}