Files
nix-config/modules/nixos/base/ssh.nix
T
Ryan Yin 662316c18a Nixos 26.05 (#261)
* flake.lock: Update

Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/7aaa00e7cc9be6c316cb5f6617bd740dd435c59d?narHash=sha256-WacE23EbHTsBKvr8cu%2B1DFNbP6Rh1brHUH5SDUI0NQI%3D' (2026-04-30)
  → 'github:NixOS/nixpkgs/e9a7635a57597d9754eccebdfc7045e6c8600e6b?narHash=sha256-u6WU/yd/o8iYQrHX3RAwO1hYa3LkoSL%2BWNQD0rJfJZQ%3D' (2026-05-29)

* feat: upgrade to nixos 26.05
2026-06-01 10:02:49 +08:00

21 lines
646 B
Nix

{ lib, ... }:
{
# Or disable the firewall altogether.
networking.firewall.enable = lib.mkDefault false;
# Enable the OpenSSH daemon.
services.openssh = {
enable = true;
settings = {
X11Forwarding = true;
# root user is used for remote deployment, so we need to allow it
PermitRootLogin = "prohibit-password";
PasswordAuthentication = false; # disable password login
};
openFirewall = true;
};
# Add terminfo database of all known terminals to the system profile.
# https://github.com/NixOS/nixpkgs/blob/nixos-26.05/nixos/modules/config/terminfo.nix
environment.enableAllTerminfo = true;
}