Files
nix-config/modules/nixos/base/ssh.nix
T
ryan4yin | 二花 42641e2fdf feat!: replace zellij with tuios, default to ghostty + kitty (#349)
* feat!: replace zellij with tuios and switch to ghostty + kitty

Terminal environment overhaul:

- add the tuios flake input (upstream 0.8.5; nixpkgs has 0.8.1) and link
  the checked-in config out-of-store; auto-start tuios in nushell instead
  of zellij
- remove zellij entirely: both modules, config, README and nushell
  completions
- remove foot and alacritty, which lack the Kitty graphics protocol;
2026-10-03 02:34:31 +08:00

27 lines
956 B
Nix

{ lib, pkgs, ... }:
{
# Secure by default: firewall ON everywhere. Servers run the same shared
# firewall (modules/nixos/base/networking/firewall.nix) as every other host,
# as defence in depth behind the router.
networking.firewall.enable = lib.mkDefault true;
# Enable the OpenSSH daemon.
services.openssh = {
enable = true;
settings = {
# Secure by default: X11 forwarding off everywhere; desktops re-enable it
# in modules/nixos/desktop/ssh.nix (needed for GUI forwarding).
X11Forwarding = lib.mkDefault false;
# root user is used for remote deployment, so we need to allow it
PermitRootLogin = lib.mkDefault "prohibit-password";
PasswordAuthentication = false; # disable password login
};
openFirewall = true;
};
# Terminfo for the terminals we use, so `$TERM` resolves on hosts we SSH into.
environment.systemPackages = [
pkgs.ghostty.terminfo
pkgs.kitty.terminfo
];
}