feat: setup rule to allow access from wan
This commit is contained in:
parent
74cd7c4859
commit
7021603e4e
2 changed files with 9 additions and 1 deletions
|
|
@ -57,6 +57,11 @@ let
|
|||
|
||||
in {
|
||||
options.cloonar-assistant = {
|
||||
setup = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Enable access from Wan to Setup";
|
||||
};
|
||||
networkPrefix = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
example = "10.42";
|
||||
|
|
@ -165,6 +170,6 @@ in {
|
|||
./networking
|
||||
./updns
|
||||
./home-assistant
|
||||
./multiroom-audio
|
||||
# ./multiroom-audio
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,6 +34,9 @@ in {
|
|||
chain input-allow {
|
||||
udp dport != { 53, 5353 } ct state new limit rate over 1/second burst 10 packets drop comment "rate limit for new connections"
|
||||
iifname lo accept
|
||||
${lib.optionalString config.cloonar-assistant.setup ''
|
||||
iifname "wan" accept
|
||||
''}
|
||||
${lib.optionalString config.cloonar-assistant.vpn.enable ''
|
||||
iifname "wan" udp dport 51820 counter accept comment "Wireguard traffic"
|
||||
''}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue