summaryrefslogtreecommitdiff
path: root/scripts/vyos-update-nhrp.pl
diff options
context:
space:
mode:
authorKim Hagen <khagen@multi-development.com>2014-08-25 11:36:22 +0200
committerKim Hagen <khagen@multi-development.com>2014-08-25 11:36:22 +0200
commit2484447ac37791188feae6b9bf2e5213a7682abc (patch)
tree9c637a5c902df366324bb5326501551b134f28ad /scripts/vyos-update-nhrp.pl
parent818b4863c1047ce597a72943dc7b4d49b6f0e4dc (diff)
downloadvyos-nhrp-2484447ac37791188feae6b9bf2e5213a7682abc.tar.gz
vyos-nhrp-2484447ac37791188feae6b9bf2e5213a7682abc.zip
Add 'shortcut-target' option
Diffstat (limited to 'scripts/vyos-update-nhrp.pl')
-rw-r--r--scripts/vyos-update-nhrp.pl9
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/vyos-update-nhrp.pl b/scripts/vyos-update-nhrp.pl
index de91173..7f4d62a 100644
--- a/scripts/vyos-update-nhrp.pl
+++ b/scripts/vyos-update-nhrp.pl
@@ -203,6 +203,15 @@ sub tunnel_config {
unshift(@conf_file, "interface $tunnel_ID $type\n");
push(@conf_file, "\n");
}
+ if ( $tunnel_Config->exists("$tunnel_ID shortcut-target")) {
+ my @starget = $tunnel_Config->listNodes("$tunnel_ID shortcut-target");
+ my $starget = $starget[0];
+ push(@conf_file, " shortcut-target", " $starget");
+ push(@conf_file, " ", $tunnel_Config->returnValue("$tunnel_ID shortcut-target $starget holding-time"));
+ shift(@conf_file);
+ unshift(@conf_file, "interface $tunnel_ID $type\n");
+ push(@conf_file, "\n");
+ }
if ($tunnel_Config->returnValue("$tunnel_ID cisco-authentication") ne "") {
push(@conf_file, " cisco-authentication ", $tunnel_Config->returnValue("$tunnel_ID cisco-authentication") , "\n");
}