WIP add zones to firewall module
- zones are an attrset of name -> [interface-service] - the firewall will create empty "ifname" sets for each zone name in each address family (ip, ip6) - then watch the interface services, and add the "ifname" outputs to the corresponding sets when they appear This commit only adds the empty sets
This commit is contained in:
@@ -48,6 +48,9 @@ in {
|
||||
firewall = {
|
||||
enable = mkEnableOption "firewall";
|
||||
rules = mkOption { type = types.attrsOf types.attrs; };
|
||||
zones = mkOption {
|
||||
type = types.attrsOf (types.listOf liminix.lib.types.service);
|
||||
};
|
||||
};
|
||||
|
||||
wan = {
|
||||
@@ -143,6 +146,7 @@ in {
|
||||
services.firewall = mkIf cfg.firewall.enable
|
||||
(svc.firewall.build {
|
||||
extraRules = cfg.firewall.rules;
|
||||
inherit (cfg.firewall) zones;
|
||||
});
|
||||
|
||||
services.resolvconf = oneshot rec {
|
||||
|
Reference in New Issue
Block a user