cluster/services/dns: create dns records for machines

This commit is contained in:
Max Headroom 2023-12-03 16:32:00 +01:00
parent 2a9fdfa4f9
commit a09b8ff7c5
2 changed files with 12 additions and 0 deletions

View file

@ -7,6 +7,7 @@ in
{ {
imports = [ imports = [
./options.nix ./options.nix
./nodes.nix
]; ];
links = { links = {

View file

@ -0,0 +1,11 @@
{ depot, lib, ... }:
{
dns.records = lib.mapAttrs' (name: hour: {
name = lib.toLower "${name}.${hour.enterprise.subdomain}";
value = {
type = "A";
target = [ hour.interfaces.primary.addrPublic ];
};
}) depot.gods.fromLight;
}