properly inherit enable on servers
This commit is contained in:
@@ -5,16 +5,12 @@ let
|
||||
in
|
||||
{
|
||||
options.my.servers.shiori = setup.mkOptions "shiori" "bookmarks" 4368;
|
||||
config =
|
||||
lib.mkIf
|
||||
(config.my.servers.shiori.enable && config.my.servers.postgres.enable && config.my.secureHost)
|
||||
{
|
||||
sops.secrets.shiori.sopsFile = ../../secrets/env.yaml;
|
||||
services.shiori = {
|
||||
inherit (cfg) port;
|
||||
enable = true;
|
||||
environmentFile = config.sops.secrets.shiori.path;
|
||||
databaseUrl = "postgres:///shiori?host=${config.my.postgresSocket}";
|
||||
};
|
||||
};
|
||||
config = lib.mkIf (cfg.enable && config.my.servers.postgres.enable && config.my.secureHost) {
|
||||
sops.secrets.shiori.sopsFile = ../../secrets/env.yaml;
|
||||
services.shiori = {
|
||||
inherit (cfg) enable port;
|
||||
environmentFile = config.sops.secrets.shiori.path;
|
||||
databaseUrl = "postgres:///shiori?host=${config.my.postgresSocket}";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user