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