fix(meta): Only define targetHost when the network config is defined
All checks were successful
Check meta / check_dns (push) Successful in 19s
Check meta / check_meta (push) Successful in 25s
Build all the nodes / geo02 (push) Successful in 1m24s
Build all the nodes / bridge01 (push) Successful in 1m39s
Build all the nodes / geo01 (push) Successful in 1m46s
Build all the nodes / compute01 (push) Successful in 1m58s
Build all the nodes / rescue01 (push) Successful in 1m51s
Build all the nodes / storage01 (push) Successful in 1m44s
Run pre-commit on all files / check (push) Successful in 29s
Build all the nodes / vault01 (push) Successful in 1m29s
Build all the nodes / web02 (push) Successful in 1m28s
Build all the nodes / web01 (push) Successful in 2m6s
Build all the nodes / web03 (push) Successful in 1m58s

This commit is contained in:
Tom Hubrecht 2024-12-08 12:49:46 +01:00
parent e1586b4873
commit c3f4e7ade6
Signed by: thubrecht
SSH key fingerprint: SHA256:r+nK/SIcWlJ0zFZJGHtlAoRwq1Rm+WcKAm5ADYMoQPc

View file

@ -205,11 +205,12 @@ in
config = {
deployment = {
tags = [ "infra-${config.site}" ];
targetHost =
targetHost = mkIf (builtins.hasAttr name args.config.network) (
let
ip = with args.config.network.${name}.addresses; ipv4 ++ ipv6;
in
mkIf (ip != [ ]) (mkDefault (builtins.head ip));
mkIf (ip != [ ]) (mkDefault (builtins.head ip))
);
};
};
}