nebula/sshd: Hardcode port 22

This commit is contained in:
SebastianStork 2026-01-11 14:14:01 +01:00
parent 3cf75dc7e1
commit e0b6239ab6
Signed by: SebastianStork
SSH key fingerprint: SHA256:tRrGdjYOwgHxpSc/wTOZQZEjxcb15P0tyXRsbAfd+2Q

View file

@ -8,18 +8,12 @@ let
cfg = config.custom.services.nebula.node;
in
{
options.custom.services.nebula.node.sshd = {
enable = lib.mkEnableOption "" // {
options.custom.services.nebula.node.sshd.enable = lib.mkEnableOption "" // {
default = true;
};
port = lib.mkOption {
type = lib.types.port;
default = 22;
};
};
config = lib.mkIf (cfg.enable && cfg.sshd.enable) {
meta.ports.tcp = [ cfg.sshd.port ];
meta.ports.tcp = [ 22 ];
services = {
openssh = {
@ -28,7 +22,7 @@ in
ports = [ ];
listenAddresses = lib.singleton {
addr = cfg.address;
inherit (cfg.sshd) port;
port = 22;
};
settings = {
PasswordAuthentication = false;
@ -41,7 +35,7 @@ in
config.custom.services.nebula.peers
|> lib.filter (node: node.isClient)
|> lib.map (nebula: {
inherit (cfg.sshd) port;
port = 22;
proto = "tcp";
host = nebula.name;
});