mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-06-16 18:15:13 -05:00
refactor: complete overhaul
This commit is contained in:
parent
fb3e6fed86
commit
0541b3d61f
154 changed files with 936 additions and 904 deletions
39
systems/server/config/networking.nix
Executable file
39
systems/server/config/networking.nix
Executable file
|
@ -0,0 +1,39 @@
|
|||
{
|
||||
lib,
|
||||
flake,
|
||||
...
|
||||
}: let
|
||||
inherit (flake.config.machines.devices) server;
|
||||
in {
|
||||
networking = {
|
||||
hostName = server.name;
|
||||
networkmanager.enable = true;
|
||||
nftables.enable = true;
|
||||
useDHCP = lib.mkDefault true;
|
||||
firewall = {
|
||||
enable = true;
|
||||
allowedTCPPorts = [
|
||||
22 # SSH
|
||||
25 # SMTP
|
||||
139 # SMTP
|
||||
587 # SMTP
|
||||
];
|
||||
};
|
||||
};
|
||||
services = {
|
||||
avahi = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
nssmdns4 = true;
|
||||
publish = {
|
||||
enable = true;
|
||||
userServices = true;
|
||||
};
|
||||
};
|
||||
sshd.enable = true;
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings.PasswordAuthentication = false;
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue