More util functions
This commit is contained in:
parent
4688003535
commit
7629a979b4
9
lib.nix
9
lib.nix
|
@ -36,8 +36,13 @@ let
|
|||
getDomainHosts = domain:
|
||||
attrNames
|
||||
(filterAttrs (_: hostOpts: hostOpts.domain == domain) entities.hosts);
|
||||
|
||||
getSiteGateway = site: entities.sites."${site-name}".gateway-v4;
|
||||
|
||||
getHostGateway = hostname: (getHostSite hostname).gateway-v4;
|
||||
|
||||
in {
|
||||
inherit getHostSite getHostDomain getHostRealm getHostFqdn getHostIpv4
|
||||
getHostIpv6 getHostIps getDomainPostgresqlServer getSiteHosts
|
||||
getDomainHosts;
|
||||
getHostIpv6 getHostIps getDomainPostgresqlServer getSiteHosts getDomainHosts
|
||||
getSiteGateway getHostGateway;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue