diff --git a/common/default.nix b/common/default.nix index 5aa7930..8409a8e 100755 --- a/common/default.nix +++ b/common/default.nix @@ -2,6 +2,8 @@ { imports = [ + ./ssh + ./boot.nix ./home-manager.nix ./locales.nix diff --git a/modules/nixos/ssh.nix b/common/ssh/client.nix similarity index 64% rename from modules/nixos/ssh.nix rename to common/ssh/client.nix index 2cf7c2c..019d802 100755 --- a/modules/nixos/ssh.nix +++ b/common/ssh/client.nix @@ -19,21 +19,8 @@ "; }; - services.openssh = { - enable = true; - ports = [ 8743 ]; - settings = { - PasswordAuthentication = false; - KbdInteractiveAuthentication = false; - PermitRootLogin = "no"; - AllowUsers = [ "wo2w" ]; - }; - }; - environment = { systemPackages = if config.services.desktopManager.plasma6.enable then with pkgs; [ kdePackages.ksshaskpass ] else []; - variables = { - SSH_ASKPASS_REQUIRE = "prefer"; - }; + variables.SSH_ASKPASS_REQUIRE = "prefer"; }; } \ No newline at end of file diff --git a/common/ssh/default.nix b/common/ssh/default.nix new file mode 100644 index 0000000..a50f050 --- /dev/null +++ b/common/ssh/default.nix @@ -0,0 +1,8 @@ +{ config, ... }: + +{ + imports = [ + ./client.nix + ./server.nix + ]; +} \ No newline at end of file diff --git a/common/ssh/server.nix b/common/ssh/server.nix new file mode 100644 index 0000000..6dbcd23 --- /dev/null +++ b/common/ssh/server.nix @@ -0,0 +1,14 @@ +{ config, ... }: + +{ + services.openssh = { + enable = true; + ports = [ 8743 ]; + settings = { + PasswordAuthentication = false; + KbdInteractiveAuthentication = false; + PermitRootLogin = "no"; + AllowUsers = [ "wo2w" ]; + }; + }; +} \ No newline at end of file