2024-01-14 06:29:18 +08:00
|
|
|
{ ... }:
|
|
|
|
|
|
|
|
{
|
|
|
|
services.openssh = {
|
|
|
|
enable = true;
|
|
|
|
settings = {
|
|
|
|
PermitRootLogin = "no";
|
|
|
|
PasswordAuthentication = false;
|
2024-06-13 21:37:38 +08:00
|
|
|
LogLevel = "VERBOSE";
|
2024-01-14 06:29:18 +08:00
|
|
|
};
|
2024-07-09 09:49:10 +08:00
|
|
|
ports = [ 22 ];
|
2024-01-14 06:29:18 +08:00
|
|
|
openFirewall = true;
|
|
|
|
};
|
2024-06-13 21:37:38 +08:00
|
|
|
|
|
|
|
services.rsyslogd = {
|
|
|
|
enable = true;
|
|
|
|
extraConfig = ''
|
|
|
|
if $programname == 'sshd' then /var/log/sshd.log
|
|
|
|
'';
|
|
|
|
};
|
2024-01-14 06:29:18 +08:00
|
|
|
}
|