mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-08-10 13:54:38 -05:00
feat: server test
This commit is contained in:
parent
0b802c39ad
commit
38ba756246
5 changed files with 42 additions and 17 deletions
|
@ -1,7 +1,5 @@
|
|||
let
|
||||
modulesPath = ./modules;
|
||||
servicePath = modulesPath + "/services";
|
||||
|
||||
moduleImport = path: nameTransform:
|
||||
builtins.listToAttrs (
|
||||
map
|
||||
|
@ -15,10 +13,22 @@ let
|
|||
(builtins.attrNames (builtins.readDir path))
|
||||
)
|
||||
);
|
||||
|
||||
modules =
|
||||
moduleImport modulesPath (name: builtins.replaceStrings [".nix"] [""] name)
|
||||
// moduleImport servicePath (name: builtins.replaceStrings [".nix"] [""] name);
|
||||
// (path:
|
||||
builtins.listToAttrs (
|
||||
map
|
||||
(name: {
|
||||
name = name;
|
||||
value = import (path + "/${name}");
|
||||
})
|
||||
(
|
||||
builtins.filter
|
||||
(name: (builtins.readDir path).${name} == "directory")
|
||||
(builtins.attrNames (builtins.readDir path))
|
||||
)
|
||||
))
|
||||
modulesPath;
|
||||
in {
|
||||
flake.nixosModules = {
|
||||
personal = {
|
||||
|
@ -59,19 +69,7 @@ in {
|
|||
imports = builtins.attrValues {
|
||||
inherit
|
||||
(modules)
|
||||
acme
|
||||
caddy
|
||||
jellyfin
|
||||
logrotate
|
||||
mastodon
|
||||
minecraft
|
||||
nextcloud
|
||||
ollama
|
||||
owncast
|
||||
peertube
|
||||
postgresql
|
||||
samba
|
||||
vaultwarden
|
||||
services
|
||||
;
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue