nixos-config/modules/common/network.nix

30 lines
591 B
Nix
Raw Normal View History

2024-12-10 12:59:37 +01:00
{ lib, ... }:
with lib;
{
config = {
networking.networkmanager.enable = true;
networking.useDHCP = mkDefault true;
networking.firewall.enable = true;
2024-12-10 12:59:37 +01:00
services.openssh = {
enable = true;
settings = {
StrictModes = true;
PasswordAuthentication = false;
KbdInteractiveAuthentication = false;
PermitEmptyPasswords = "no";
};
openFirewall = true;
hostKeys = [
{
comment = "Main key";
path = "/etc/ssh/ssh_host_ed25519_key";
type = "ed25519";
}
];
};
};
}