self-hosting/modules/openssh.nix
Paul-Henri Froidmont af6158289c
Remove laptop ssh key
2025-12-24 00:55:38 +01:00

20 lines
488 B
Nix

{ config, lib, ... }:
with lib;
let
cfg = config.custom.services.openssh;
in
{
options.custom.services.openssh = {
enable = mkEnableOption "openssh";
};
config = mkIf cfg.enable {
services.openssh.enable = true;
services.openssh.settings.PermitRootLogin = "prohibit-password";
users.users.root.openssh.authorizedKeys.keyFiles = [
../ssh_keys/froidmpa-desktop.pub
../ssh_keys/phfroidmont-stellaris.pub
../ssh_keys/elios-desktop.pub
];
};
}