Compare commits

...

No commits in common. "7a396ada3b20305552a9c44b7a06a09a9ef0cf56" and "6f2d0b13c132d783d77061a08c4d1552f3e0f1dc" have entirely different histories.

4 changed files with 15 additions and 10 deletions

View file

@ -27,7 +27,7 @@
}; };
networking = { networking = {
firewall.enable = true; firewall.enable = false;
networkmanager = { networkmanager = {
enable = true; enable = true;
wifi.macAddress = "random"; wifi.macAddress = "random";
@ -84,6 +84,7 @@
}; };
}]; }];
}; };
localsend.openFirewall = true;
}; };
services = { services = {

View file

@ -2,7 +2,7 @@
{ {
imports = [ imports = [
./localsend.nix ./firewall-rules/localsend.nix
./networkmanager/auto-wlan.nix ./networkmanager/auto-wlan.nix
./networkmanager/systemd-wait-online.nix ./networkmanager/systemd-wait-online.nix
]; ];

View file

@ -0,0 +1,12 @@
{ config, lib, ... }:
{
config = lib.mkIf config.programs.localsend.openFirewall {
networking.firewall = {
allowedTCPPorts = [ 53317 ];
allowedUDPPorts = [ 53317 ];
};
};
options.programs.localsend.openFirewall = lib.mkEnableOption "open the default ports for localsend";
}

View file

@ -1,8 +0,0 @@
{ ... }:
{
networking.firewall = {
allowedTCPPorts = [ 53317 ];
allowedUDPPorts = [ 53317 ];
};
}