diff --git a/cluster/services/idm/default.nix b/cluster/services/idm/default.nix index c8a5b80..279316d 100644 --- a/cluster/services/idm/default.nix +++ b/cluster/services/idm/default.nix @@ -34,4 +34,22 @@ ]; }; }; + + dns.records = let + serverAddrsPublic = map + (node: depot.hours.${node}.interfaces.primary.addrPublic) + config.services.idm.nodes.server; + serverAddrsInternal = map + (node: config.vars.mesh.${node}.meshIp) + config.services.idm.nodes.server; + in { + idm = { + type = "A"; + target = serverAddrsPublic; + }; + "idm-ldap.internal" = { + type = "A"; + target = serverAddrsInternal; + }; + }; }