dotfiles/modules/config/instances/default.nix

40 lines
961 B
Nix
Raw Normal View History

2024-11-10 01:29:37 -06:00
let
configPath = ./config;
instancesFunctions = {
jellyfinLabel = "Jellyfin";
jellyfinName = "jellyfin";
2025-03-18 23:05:15 -05:00
audiobookshelfLabel = "Audiobookshelf";
audiobookshelfName = "audiobookshelf";
2024-11-10 01:29:37 -06:00
domain0 = "cloudbert.fun";
domain1 = "the-nutrivore.social";
domain2 = "the-nutrivore.com";
2024-12-08 22:53:40 -06:00
domain3 = "uprootnutrition.com";
2024-11-10 01:29:37 -06:00
servicePath = "/mnt/media/NAS1";
sopsPath = "/var/lib/secrets";
sslPath = "/var/lib/acme";
varLib = "/var/lib";
2025-02-02 20:51:18 -06:00
dummy = "";
2024-11-10 01:29:37 -06:00
};
2025-02-02 20:51:18 -06:00
instances = builtins.listToAttrs (
map
(name: {
name = builtins.substring 0 (builtins.stringLength name - 4) name;
value = import (configPath + "/${name}") {
inherit
instancesFunctions
;
};
})
(
builtins.filter (name: builtins.match ".*\\.nix$" name != null) (
builtins.attrNames (builtins.readDir configPath)
)
)
);
in
{
2024-11-10 01:29:37 -06:00
instances = instances;
}