aboutsummaryrefslogtreecommitdiff
path: root/profiles/core/ssh.nix
blob: f8c899a479a5792739b3c9150ad5e82ccd4db4ed (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{ lib, ... }:
{
  services.openssh = {
    enable = lib.mkDefault true;
    settings = {
      PasswordAuthentication = lib.mkForce false;
      KbdInteractiveAuthentication = lib.mkForce false;

      PermitRootLogin = lib.mkForce "prohibit-password";
    };
    openFirewall = lib.mkDefault true;
    hostKeys = [
      {
        path = "/etc/ssh/ssh_host_ed25519_key";
        type = "ed25519";
      }
    ];
  };
}