Files
alo-cluster/hosts/common/sshd.nix

22 lines
426 B
Nix

{
services.openssh = {
enable = true;
allowSFTP = true;
settings = {
PasswordAuthentication = false;
KbdInteractiveAuthentication = false;
};
extraConfig = ''
AllowTcpForwarding yes
X11Forwarding no
AllowAgentForwarding no
AllowStreamLocalForwarding no
AuthenticationMethods publickey
'';
};
networking.firewall = {
allowedTCPPorts = [ 22 ];
};
}