Allow repeated sections to hostname

This commit is contained in:
niten 2023-10-07 09:47:29 -07:00
parent ec7e11c0f7
commit 071866cbd6
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@ let
hostToFqdn = host: hostToFqdn = host:
if isNotNull (builtins.match "[^.]+\\.$" host) then if isNotNull (builtins.match "[^.]+\\.$" host) then
host host
else if isNotNull (builtins.match "[^.]+\\.[^.]+$" host) then else if isNotNull (builtins.match "([^.]+\\.)+[^.]+$" host) then
"${host}." "${host}."
else if (hasAttr host zone.hosts) then else if (hasAttr host zone.hosts) then
"${host}.${domain}." "${host}.${domain}."