refactor: Modularise Nginx vhosts

This commit is contained in:
Madeleine Sydney
2025-01-19 18:52:23 -07:00
parent 46d6c129c1
commit f4924eeb59
11 changed files with 213 additions and 171 deletions

View File

@@ -0,0 +1,15 @@
{ config, lib, pkgs, ... }:
let
# TODO: Move to a fucking utility library already!
listNixFilesInDirectory = dir:
builtins.attrNames
(lib.filterAttrs
(k: _v: lib.hasSuffix ".nix" k)
(builtins.readDir dir));
in {
imports =
builtins.map
(k: ./deertopia/${k})
(listNixFilesInDirectory ./deertopia);
}