summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/vyatta-cfg-firewall.install1
-rwxr-xr-xgen-interface-templates.pl10
2 files changed, 11 insertions, 0 deletions
diff --git a/debian/vyatta-cfg-firewall.install b/debian/vyatta-cfg-firewall.install
index 633b9e0..57693ee 100644
--- a/debian/vyatta-cfg-firewall.install
+++ b/debian/vyatta-cfg-firewall.install
@@ -10,5 +10,6 @@ opt/vyatta/share/vyatta-cfg/templates/interfaces/input
opt/vyatta/share/vyatta-cfg/templates/interfaces/openvpn
opt/vyatta/share/vyatta-cfg/templates/interfaces/pseudo-ethernet
opt/vyatta/share/vyatta-cfg/templates/interfaces/tunnel
+opt/vyatta/share/vyatta-cfg/templates/interfaces/vti
opt/vyatta/share/vyatta-cfg/templates/interfaces/wireless
opt/vyatta/share/vyatta-cfg/templates/interfaces/wirelessmodem
diff --git a/gen-interface-templates.pl b/gen-interface-templates.pl
index 3f7a232..9a9dc41 100755
--- a/gen-interface-templates.pl
+++ b/gen-interface-templates.pl
@@ -55,6 +55,7 @@ my %interface_hash = (
'input/node.tag' => '$VAR(../../../@)',
'tunnel/node.tag' => '$VAR(../../../@)',
+ 'vti/node.tag' => '$VAR(../../../@)',
'bridge/node.tag' => '$VAR(../../../@)',
'openvpn/node.tag' => '$VAR(../../../@)',
@@ -70,6 +71,12 @@ my %interface_hash = (
'wirelessmodem/node.tag' => '$VAR(../../../@)',
);
+# Hash table to check if the priority needs to set @ root
+# of the node.def which is generated.
+my %interface_prio = (
+ 'vti/node.tag' => '901',
+);
+
# The subdirectory where the generated templates will go
my $template_subdir = "generated-templates/interfaces";
@@ -102,6 +109,9 @@ sub gen_firewall_template {
open my $tp, '>', "$path/$node_file"
or die "Can't create $path/$node_file: $!";
+ if (exists $interface_prio{ $if_tree }) {
+ print $tp "priority: $interface_prio{ $if_tree }\n";
+ }
print $tp "help: Firewall options\n";
close $tp
or die "Can't write $path/$node_file: $!";