summaryrefslogtreecommitdiff
path: root/templates/protocols/ospf/area
diff options
context:
space:
mode:
authorrbalocca <rbalocca@vyatta.com>2008-04-09 12:04:39 -0700
committerrbalocca <rbalocca@vyatta.com>2008-04-09 12:04:39 -0700
commitc9b4583f38f4bc7fedef6f05d31ef7ea2020473a (patch)
tree90e329b103b904144fef2f1eea2e6cb620ab215c /templates/protocols/ospf/area
parentd26b9a2c82d8df98211d2362a3b235f8420eb0d1 (diff)
parent67c9ab299d135e8866e81868843197dd3aa78d02 (diff)
downloadvyatta-cfg-quagga-c9b4583f38f4bc7fedef6f05d31ef7ea2020473a.tar.gz
vyatta-cfg-quagga-c9b4583f38f4bc7fedef6f05d31ef7ea2020473a.zip
Merge branch 'glendale' into hollywood
Diffstat (limited to 'templates/protocols/ospf/area')
-rw-r--r--templates/protocols/ospf/area/node.tag/area-type/nssa/default-cost/node.def22
-rw-r--r--templates/protocols/ospf/area/node.tag/area-type/nssa/no-summary/node.def6
-rw-r--r--templates/protocols/ospf/area/node.tag/area-type/nssa/node.def27
-rw-r--r--templates/protocols/ospf/area/node.tag/area-type/nssa/translate/node.def7
-rw-r--r--templates/protocols/ospf/area/node.tag/area-type/stub/default-cost/node.def20
5 files changed, 53 insertions, 29 deletions
diff --git a/templates/protocols/ospf/area/node.tag/area-type/nssa/default-cost/node.def b/templates/protocols/ospf/area/node.tag/area-type/nssa/default-cost/node.def
index 95f73f69..21a486a7 100644
--- a/templates/protocols/ospf/area/node.tag/area-type/nssa/default-cost/node.def
+++ b/templates/protocols/ospf/area/node.tag/area-type/nssa/default-cost/node.def
@@ -1,11 +1,19 @@
type: u32
help: Set the summary-default cost of nssa area
syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 16777215; "Cost must be between 0-16777215"
-update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"area $VAR(../../../@) default-cost $VAR(@)\"; "
-delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"no area $VAR(../../../@) default-cost $VAR(@)\"; "
+
+create: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "area $VAR(../../../@) nssa" \
+ -c "area $VAR(../../../@) default-cost $VAR(@)";
+
+update: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "area $VAR(../../../@) default-cost $VAR(@)";
+
+delete: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "no area $VAR(../../../@) default-cost $VAR(@)";
+
comp_help: possible completions:
- <0-16777215> Set summary default cost
+ <0-16777215> Set summary default cost
diff --git a/templates/protocols/ospf/area/node.tag/area-type/nssa/no-summary/node.def b/templates/protocols/ospf/area/node.tag/area-type/nssa/no-summary/node.def
index fa1f76e4..4999ff7a 100644
--- a/templates/protocols/ospf/area/node.tag/area-type/nssa/no-summary/node.def
+++ b/templates/protocols/ospf/area/node.tag/area-type/nssa/no-summary/node.def
@@ -1,7 +1 @@
help: Do not inject inter-area routes into stub
-create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"area $VAR(../../../@) nssa no-summary \"; "
-delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"no area $VAR(../../../@) nssa no-summary \"; "
diff --git a/templates/protocols/ospf/area/node.tag/area-type/nssa/node.def b/templates/protocols/ospf/area/node.tag/area-type/nssa/node.def
index 9ac0569f..b27f0b3a 100644
--- a/templates/protocols/ospf/area/node.tag/area-type/nssa/node.def
+++ b/templates/protocols/ospf/area/node.tag/area-type/nssa/node.def
@@ -2,7 +2,26 @@ help: nssa OSPF area
syntax:expression: ! $VAR(../../@) in "0", "0.0.0.0"; "Backbone can't be NSSA"
syntax:expression: $VAR(../normal/) == "" ; "Must delete normal area type first"
syntax:expression: $VAR(../stub/) == "" ; "Must delete stub area type first"
-update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" -c \"area $VAR(../../@) nssa\"; "
-delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" -c \"no area $VAR(../../@) nssa\"; "
+
+delete: touch /tmp/ospf-area-nssa.$PPID
+end: if [ -f "/tmp/ospf-area-nssa.$PPID" ]; then
+ ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" -c "no area $VAR(../../@) nssa";
+ rm /tmp/ospf-area-nssa.$PPID;
+ else
+ if [ -n "$VAR(translate/@)" ]; then
+ PARM="translate-$VAR(translate/@)";
+ fi;
+ # using workaround pending bug 2525
+ #
+ # if [ -n "$VAR(no-summary/)" ]; then
+ # PARM="$PARM no-summary";
+ # fi;
+ ${vyatta_sbindir}/vyatta-check-typeless-node.pl \
+ "protocols ospf area $VAR(../../@) area-type nssa no-summary";
+ if [ $? -eq 0 ] ; then
+ PARM="$PARM no-summary";
+ fi;
+ ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" -c "area $VAR(../../@) nssa $PARM";
+ fi;
diff --git a/templates/protocols/ospf/area/node.tag/area-type/nssa/translate/node.def b/templates/protocols/ospf/area/node.tag/area-type/nssa/translate/node.def
index ff32811f..9b6db051 100644
--- a/templates/protocols/ospf/area/node.tag/area-type/nssa/translate/node.def
+++ b/templates/protocols/ospf/area/node.tag/area-type/nssa/translate/node.def
@@ -2,12 +2,7 @@ type: txt
help: Configure NSSA-ABR
default: "candidate"
syntax:expression: $VAR(@) in "always", "candidate", "never"; "Must be (always, candidate, or never)"
-update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"area $VAR(../../../@) nssa translate-$VAR(@) \"; "
-delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"area $VAR(../../../@) nssa translate-candidate \"; "
+
comp_help: possible completions:
always Configure NSSA-ABR to always translate
candidate Configure NSSA-ABR for translate election (default)
diff --git a/templates/protocols/ospf/area/node.tag/area-type/stub/default-cost/node.def b/templates/protocols/ospf/area/node.tag/area-type/stub/default-cost/node.def
index cc7d96fa..78c28760 100644
--- a/templates/protocols/ospf/area/node.tag/area-type/stub/default-cost/node.def
+++ b/templates/protocols/ospf/area/node.tag/area-type/stub/default-cost/node.def
@@ -1,11 +1,19 @@
type: u32
help: Set the summary-default cost of stub area
syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 16777215; "Cost must be between 0-16777215"
-update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"area $VAR(../../../@) default-cost $VAR(@)\"; "
-delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \
- -c \"router ospf\" \
- -c \"no area $VAR(../../../@) default-cost $VAR(@)\"; "
+
+create: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "area $VAR(../../../@) stub" \
+ -c "area $VAR(../../../@) default-cost $VAR(@)";
+
+update: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "area $VAR(../../../@) default-cost $VAR(@)";
+
+delete: ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \
+ -c "router ospf" \
+ -c "no area $VAR(../../../@) default-cost $VAR(@)";
+
comp_help: possible completions:
<0-16777215> Set summary default cost of stub area