nixos-module/firewall: fix allowing ospf on routers
This commit is contained in:
parent
19527e47fd
commit
65127a79aa
|
@ -3,12 +3,11 @@
|
||||||
let
|
let
|
||||||
hostConfig = config.site.hosts.${hostName};
|
hostConfig = config.site.hosts.${hostName};
|
||||||
|
|
||||||
in
|
in {
|
||||||
lib.mkIf hostConfig.firewall.enable {
|
networking.firewall = lib.mkIf hostConfig.firewall.enable {
|
||||||
networking.firewall = {
|
|
||||||
enable = true;
|
enable = true;
|
||||||
extraCommands = ''
|
extraCommands = ''
|
||||||
${lib.optional hostConfig.isRouter ''
|
${lib.optionalString hostConfig.isRouter ''
|
||||||
ip46tables -I nixos-fw -p ospfigp -j ACCEPT
|
ip46tables -I nixos-fw -p ospfigp -j ACCEPT
|
||||||
''}
|
''}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue