use colmena name instead of networking.hostName

This commit is contained in:
asyncnomi 2025-07-05 18:53:44 +02:00
parent 873479d893
commit 00312a3ffb

View file

@ -1,8 +1,9 @@
{ config, lib, network, ... }: { config, lib, network, name, ... }:
let let
inherit (lib) mkOption types; inherit (lib) mkOption types;
cfg = config.vogon; cfg = config.vogon;
node = network.infra.nodes.${name};
in in
{ {
options.vogon = { options.vogon = {
@ -50,8 +51,8 @@ in
}; };
}; };
services.openssh.listenAddresses = [ services.openssh.listenAddresses = [
{ addr = network.infra.nodes.${config.networking.hostName}.ipv4; port = 22; } { addr = node.ipv4; port = 22; }
{ addr = network.infra.nodes.${config.networking.hostName}.ipv6; port = 22; } { addr = node.ipv6; port = 22; }
] ++ map (octet: { addr = "193.54.193.${toString octet}"; port = 22; }) cfg.networking.ssh-octets; ] ++ map (octet: { addr = "193.54.193.${toString octet}"; port = 22; }) cfg.networking.ssh-octets;
}; };
} }