Add firewall and kanata configuration
Signed-off-by: George Kaklamanos <gkaklas@gkaklas.gr>
This commit is contained in:
parent
22548339a9
commit
e0e32ffc84
3 changed files with 123 additions and 0 deletions
40
nixos/firewall.nix
Normal file
40
nixos/firewall.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
networking.firewall = {
|
||||
enable = true;
|
||||
# https://docs.syncthing.net/users/firewall.html
|
||||
allowedTCPPorts = [
|
||||
# Syncthing
|
||||
8384
|
||||
22000
|
||||
];
|
||||
allowedUDPPorts = [
|
||||
# Syncthing
|
||||
22000
|
||||
21027
|
||||
];
|
||||
allowedTCPPortRanges = [
|
||||
# KDE Connect
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
}
|
||||
];
|
||||
allowedUDPPortRanges = [
|
||||
# KDE Connect
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
}
|
||||
# Mosh
|
||||
{
|
||||
from = 60000;
|
||||
to = 61000;
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue