openssh.nix 464 B

12345678910111213141516171819202122
  1. {
  2. services.openssh = {
  3. enable = true;
  4. settings = {
  5. PasswordAuthentication = false;
  6. PermitRootLogin = "no";
  7. };
  8. extraConfig = ''
  9. StreamLocalBindUnlink yes
  10. '';
  11. };
  12. # programs.ssh.knownHostsFiles = [
  13. # ../../../keys/github.keys
  14. # ../../../keys/thor.keys
  15. # ../../../keys/penguin.keys
  16. # ../../../keys/vault.keys
  17. # ];
  18. # Passwordless sudo when SSH'ing with keys
  19. security.pam.sshAgentAuth.enable = true;
  20. }