Added ssh
This commit is contained in:
19
modules/system/ssh.nix
Normal file
19
modules/system/ssh.nix
Normal file
@@ -0,0 +1,19 @@
|
||||
{ config, lib, pkgs, self, ... }:
|
||||
|
||||
let
|
||||
cfg = config.samfelag.modules.system.ssh;
|
||||
in
|
||||
{
|
||||
options.samfelag.modules.system.ssh = {
|
||||
enable = lib.mkEnableOption "ssh";
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
# TODO: Use ssh keys
|
||||
passwordAuthentication = true;
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user