From ef9afcfa51cfb72c75e26e994fe58f4690e7ab87 Mon Sep 17 00:00:00 2001 From: Bob Gilligan Date: Wed, 15 Jul 2009 11:47:24 -0700 Subject: Bugfix 4708: Change update action in non-leaf valueless node to create An "update" action in a non-leaf valueless node is only called when the node is created for the first time. So the "create" action should be used instead of "update". --- .../area/node.tag/area-type/stub/no-summary/node.def | 16 ++++++++++------ .../ospf/area/node.tag/area-type/stub/node.def | 19 +++++++++++++------ 2 files changed, 23 insertions(+), 12 deletions(-) (limited to 'templates/protocols/ospf') diff --git a/templates/protocols/ospf/area/node.tag/area-type/stub/no-summary/node.def b/templates/protocols/ospf/area/node.tag/area-type/stub/no-summary/node.def index dfcbfdf7..da351ee5 100644 --- a/templates/protocols/ospf/area/node.tag/area-type/stub/no-summary/node.def +++ b/templates/protocols/ospf/area/node.tag/area-type/stub/no-summary/node.def @@ -1,7 +1,11 @@ help: Set to not inject inter-area routes into stub -create:expression: "vyatta-vtysh -c \"configure terminal\" \ - -c \"router ospf\" \ - -c \"area $VAR(../../../@) stub no-summary \"; " -delete:expression: "vyatta-vtysh -c \"configure terminal\" \ - -c \"router ospf\" \ - -c \"no area $VAR(../../../@) stub no-summary \"; " + +create: + vyatta-vtysh -c "configure terminal" \ + -c "router ospf" \ + -c "area $VAR(../../../@) stub no-summary " + +delete: + vyatta-vtysh -c "configure terminal" \ + -c "router ospf" \ + -c "no area $VAR(../../../@) stub no-summary " diff --git a/templates/protocols/ospf/area/node.tag/area-type/stub/node.def b/templates/protocols/ospf/area/node.tag/area-type/stub/node.def index b9d2066c..ecdc091a 100644 --- a/templates/protocols/ospf/area/node.tag/area-type/stub/node.def +++ b/templates/protocols/ospf/area/node.tag/area-type/stub/node.def @@ -1,10 +1,17 @@ help: Set stub OSPF area + syntax:expression: ! $VAR(../../@) in "0", "0.0.0.0"; "Backbone can't be stub" + syntax:expression: $VAR(../nssa/) == "" ; "Must delete nssa area type first" + syntax:expression: $VAR(../normal/) == "" ; "Must delete normal area type first" -update:expression: "vyatta-vtysh -c \"configure terminal\" \ - -c \"router ospf\" \ - -c \"area $VAR(../../@) stub\"; " -delete:expression: "vyatta-vtysh -c \"configure terminal\" \ - -c \"router ospf\" \ - -c \"no area $VAR(../../@) stub\"; " + +create: + vyatta-vtysh -c "configure terminal" \ + -c "router ospf" \ + -c "area $VAR(../../@) stub" + +delete: + vyatta-vtysh -c "configure terminal" \ + -c "router ospf" \ + -c "no area $VAR(../../@) stub" -- cgit v1.2.3