From 1e99d9edce634ad9827f3971bb43a612a540de8f Mon Sep 17 00:00:00 2001 From: Daniel Langbein Date: Sat, 23 Sep 2023 19:15:54 +0200 Subject: [PATCH] refactor and add yodaNas [WIP] --- modules/fde-ssh-unlock.nix | 10 +++++----- modules/ssh-server.nix | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/fde-ssh-unlock.nix b/modules/fde-ssh-unlock.nix index 393bd49..3811535 100644 --- a/modules/fde-ssh-unlock.nix +++ b/modules/fde-ssh-unlock.nix @@ -12,11 +12,11 @@ boot.initrd.network.ssh = { enable = true; port = ( - if (config.networking.hostname == "yodaTux") || (config.networking.hostname == "yodaTab") + if (config.networking.hostName == "yodaTux") || (config.networking.hostName == "yodaTab") then 22 - else if (config.networking.hostname == "yodaYoga") + else if (config.networking.hostName == "yodaYoga") then 2225 - else if (config.networking.hostname == "yodaNas") + else if (config.networking.hostName == "yodaNas") then 2223 else throw "Please add initrd ssh port here" ); @@ -35,9 +35,9 @@ # inxi -F # boot.initrd.availableKernelModules = ( - if (config.networking.hostname == "yodaTux") + if (config.networking.hostName == "yodaTux") then [ "r8169" ] - else if (config.networking.hostname == "yodaYoga") + else if (config.networking.hostName == "yodaYoga") then [ "e1000e" ] else throw "Please add kernel module of networ card here" ); diff --git a/modules/ssh-server.nix b/modules/ssh-server.nix index d59a8d4..87ea7ad 100644 --- a/modules/ssh-server.nix +++ b/modules/ssh-server.nix @@ -5,11 +5,11 @@ services.openssh = { enable = true; ports = ( - if (config.networking.hostname == "yodaTux") || (config.networking.hostname == "yodaTab") + if (config.networking.hostName == "yodaTux") || (config.networking.hostName == "yodaTab") then [22] - else if (config.networking.hostname == "yodaYoga") + else if (config.networking.hostName == "yodaYoga") then [2224] - else if (config.networking.hostname == "yodaNas") + else if (config.networking.hostName == "yodaNas") then [2222] else throw "Please add ssh port here" );