diff options
Diffstat (limited to 'templates/protocols')
281 files changed, 1447 insertions, 1447 deletions
diff --git a/templates/protocols/bgp/node.def b/templates/protocols/bgp/node.def index 63fc0f03..5e89d91a 100644 --- a/templates/protocols/bgp/node.def +++ b/templates/protocols/bgp/node.def @@ -1,7 +1,7 @@ tag: type: u32 -help: "Configure a BGP Autonomous System on this router" +help: Configure a BGP Autonomous System on this router # TODO: non-multinode parent -syntax: $(@) >= 1 && $(@) <= 4294967294; "AS number must be between 1 and 4294967294" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router bgp $(@)\" " +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967294; "AS number must be between 1 and 4294967294" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router bgp $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/aggregate-address/node.def b/templates/protocols/bgp/node.tag/aggregate-address/node.def index 71d96db6..bcfffa66 100644 --- a/templates/protocols/bgp/node.tag/aggregate-address/node.def +++ b/templates/protocols/bgp/node.tag/aggregate-address/node.def @@ -1,19 +1,19 @@ tag: type: ipv4net -help: "Configure BGP aggregate entries" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -delete: "touch /tmp/`echo $(@) | sed 's!/!!'`.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../@)\" \ - -c \"no aggregate-address $(@)\"; \ - if [ -f \"/tmp/`echo $(@) | sed 's!/!!'`.\\$PPID\" ]; then \ - rm -rf /tmp/`echo $(@) | sed 's!/!!'`.\\$PPID; \ +help: Configure BGP aggregate entries +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +delete:expression: "touch /tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ + -c \"no aggregate-address $VAR(@)\"; \ + if [ -f \"/tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID\" ]; then \ + rm -rf /tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID; \ else \ - if [ -n \"$(./as-set/@)\" ]; then \ + if [ -n \"$VAR(./as-set/@)\" ]; then \ COND=\"as-set\"; fi; \ - if [ -n \"$(./summary-only/@)\" ]; then \ - COND=\"\\$COND summary-only\"; \ + if [ -n \"$VAR(./summary-only/@)\" ]; then \ + COND=\"$COND summary-only\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" \ - -c \"aggregate-address $(@) \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ + -c \"aggregate-address $VAR(@) $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/aggregate-address/node.tag/as-set/node.def b/templates/protocols/bgp/node.tag/aggregate-address/node.tag/as-set/node.def index 90c088a1..d4d7945f 100644 --- a/templates/protocols/bgp/node.tag/aggregate-address/node.tag/as-set/node.def +++ b/templates/protocols/bgp/node.tag/aggregate-address/node.tag/as-set/node.def @@ -1 +1 @@ -help: "Generate AS set path information" +help: Generate AS set path information diff --git a/templates/protocols/bgp/node.tag/aggregate-address/node.tag/summary-only/node.def b/templates/protocols/bgp/node.tag/aggregate-address/node.tag/summary-only/node.def index ccfbd0fa..4d8a96b2 100644 --- a/templates/protocols/bgp/node.tag/aggregate-address/node.tag/summary-only/node.def +++ b/templates/protocols/bgp/node.tag/aggregate-address/node.tag/summary-only/node.def @@ -1 +1 @@ -help: "Filter more specific routes from updates" +help: Filter more specific routes from updates diff --git a/templates/protocols/bgp/node.tag/neighbor/node.def b/templates/protocols/bgp/node.tag/neighbor/node.def index 18abf799..4950c664 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.def @@ -1,9 +1,9 @@ tag: type: txt -help: "Specify neighbor router" -syntax: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-peer-name $(@)" -update: "if [ -n \"`echo $(@) | sed 's/[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}//'`\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" -c \"neighbor $(@) peer-group\" ; \ +help: Specify neighbor router +syntax:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-peer-name $VAR(@)" +update:expression: "if [ -n \"`echo $VAR(@) | sed 's/[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}//'`\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" -c \"neighbor $VAR(@) peer-group\" ; \ fi ; " -delete: "/opt/vyatta/sbin/vyatta-bgp.pl --check-peer-groups --peergroup $(@) --as $(../@); \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" -c \"no neighbor $(@) \" " +delete:expression: "/opt/vyatta/sbin/vyatta-bgp.pl --check-peer-groups --peergroup $VAR(@) --as $VAR(../@); \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" -c \"no neighbor $VAR(@) \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/advertisement-interval/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/advertisement-interval/node.def index b789b194..fdce27db 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/advertisement-interval/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/advertisement-interval/node.def @@ -1,14 +1,14 @@ type: u32 -help: "Minimum interval between sending BGP routing updates" -syntax: $(@) >= 0 && $(@) <= 600; "must be between 0 and 600" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Minimum interval between sending BGP routing updates +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 600; "must be between 0 and 600" +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) advertisement-interval $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) advertisement-interval\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) advertisement-interval $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) advertisement-interval\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/node.def index 2536d745..6c1ab4a5 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/node.def @@ -1,17 +1,17 @@ -help: "Accept as-path with my AS present in it." -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -delete: "touch /tmp/bgp-neighbor-$(../@)-allowas-in.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) allowas-in \"; \ - if [ -f \"/tmp/bgp-neighbor-$(../@)-allowas-in.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-neighbor-$(../@)-allowas-in.\\$PPID; \ +help: Accept as-path with my AS present in it. +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +delete:expression: "touch /tmp/bgp-neighbor-$VAR(../@)-allowas-in.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) allowas-in \"; \ + if [ -f \"/tmp/bgp-neighbor-$VAR(../@)-allowas-in.$PPID\" ]; then \ + rm -rf /tmp/bgp-neighbor-$VAR(../@)-allowas-in.$PPID; \ else \ - if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ + if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) allowas-in $(./number/@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) allowas-in $VAR(./number/@)\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/number/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/number/node.def index 468dfa3c..4efe3d54 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/number/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/allowas-in/number/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Number of occurrences of AS number" -syntax: $(@) >= 1 && $(@) <= 10; "allowas-in number must be between 1 and 10" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" +help: Number of occurrences of AS number +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 10; "allowas-in number must be between 1 and 10" +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/as-path/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/as-path/node.def index a004417e..19e19fcf 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/as-path/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/as-path/node.def @@ -1 +1 @@ -help: "AS path attribute" +help: AS path attribute diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/med/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/med/node.def index ad1fd4f3..a5a7ae78 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/med/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/med/node.def @@ -1 +1 @@ -help: "Multi-exit discriminator attribute" +help: Multi-exit discriminator attribute diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/next-hop/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/next-hop/node.def index 13cba663..7c6aa538 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/next-hop/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/next-hop/node.def @@ -1 +1 @@ -help: "Nexthop attribute" +help: Nexthop attribute diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/node.def index e9114f68..936286c5 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/attribute-unchanged/node.def @@ -1,27 +1,27 @@ -help: "BGP attribute is propagated unchanged to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set attribute-unchanged for neighbor $(../@) in peer-group $(../peer-group/@)" -delete: "touch /tmp/bgp-neighbor-$(../@)-attribute-unchanged.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) attribute-unchanged \"; \ - if [ -f \"/tmp/bgp-neighbor-$(../@)-attribute-unchanged.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-neighbor-$(../@)-attribute-unchanged.\\$PPID; \ +help: BGP attribute is propagated unchanged to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set attribute-unchanged for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +delete:expression: "touch /tmp/bgp-neighbor-$VAR(../@)-attribute-unchanged.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) attribute-unchanged \"; \ + if [ -f \"/tmp/bgp-neighbor-$VAR(../@)-attribute-unchanged.$PPID\" ]; then \ + rm -rf /tmp/bgp-neighbor-$VAR(../@)-attribute-unchanged.$PPID; \ else \ - if [ -n \"$(./as-path/@)\" ]; then \ + if [ -n \"$VAR(./as-path/@)\" ]; then \ cond=\"as-path \" ; \ fi ; \ - if [ -n \"$(./med/@)\" ]; then \ - cond=\"\\$cond med \" ; \ + if [ -n \"$VAR(./med/@)\" ]; then \ + cond=\"$cond med \" ; \ fi ; \ - if [ -n \"$(./next-hop/@)\" ]; then \ - cond=\"\\$cond next-hop \" ; \ + if [ -n \"$VAR(./next-hop/@)\" ]; then \ + cond=\"$cond next-hop \" ; \ fi ; \ - if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ + if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) attribute-unchanged \\$cond\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) attribute-unchanged $cond\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/dynamic/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/dynamic/node.def index ad6926ca..8c285c3d 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/dynamic/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/dynamic/node.def @@ -1,13 +1,13 @@ -help: "Advertise dynamic capability to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Advertise dynamic capability to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) capability dynamic\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) capability dynamic\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) capability dynamic\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) capability dynamic\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/node.def index 78cab42b..9fb78194 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/node.def @@ -1 +1 @@ -help: "Advertise ORF capability to the peer" +help: Advertise ORF capability to the peer diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/node.def index 06be1587..257b2bc1 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/node.def @@ -1 +1 @@ -help: "Advertise prefix-list ORF capability to this neighbor" +help: Advertise prefix-list ORF capability to this neighbor diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/receive/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/receive/node.def index 88e30e65..70f13129 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/receive/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/receive/node.def @@ -1,14 +1,14 @@ -help: "Capability to RECEIVE the ORF to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../../../@) --neighbor $(../../../../@)" -commit: $(../../../../peer-group/) == ""; "You can't set orf capability receive for neighbor $(../../../../@) in peer-group $(../../../../peer-group/@)" -update: "if [ -n \"$(../../../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../../../remote-as/@)\"; \ +help: Capability to RECEIVE the ORF to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../../../@) --neighbor $VAR(../../../../@)" +commit:expression: $VAR(../../../../peer-group/) == ""; "You can't set orf capability receive for neighbor $VAR(../../../../@) in peer-group $VAR(../../../../peer-group/@)" +update:expression: "if [ -n \"$VAR(../../../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../../@)\" \ - -c \"neighbor $(../../../../@) \\$peer\" \ - -c \"neighbor $(../../../../@) capability orf prefix-list receive\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../../../@)\" \ - -c \"no neighbor $(../../../../@) capability orf prefix-list receive\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../../@)\" \ + -c \"neighbor $VAR(../../../../@) $peer\" \ + -c \"neighbor $VAR(../../../../@) capability orf prefix-list receive\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../../../@)\" \ + -c \"no neighbor $VAR(../../../../@) capability orf prefix-list receive\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/send/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/send/node.def index 625045b0..13b1cf40 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/send/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/capability/orf/prefix-list/send/node.def @@ -1,14 +1,14 @@ -help: "Capability to SEND the ORF to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../../../@) --neighbor $(../../../../@)" -commit: $(../../../../peer-group/) == ""; "You can't set capability orf send for neighbor $(../../../../@) in peer-group $(../../../../peer-group/@)" -update: "if [ -n \"$(../../../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../../../remote-as/@)\"; \ +help: Capability to SEND the ORF to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../../../@) --neighbor $VAR(../../../../@)" +commit:expression: $VAR(../../../../peer-group/) == ""; "You can't set capability orf send for neighbor $VAR(../../../../@) in peer-group $VAR(../../../../peer-group/@)" +update:expression: "if [ -n \"$VAR(../../../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../../@)\" \ - -c \"neighbor $(../../../../@) \\$peer\" \ - -c \"neighbor $(../../../../@) capability orf prefix-list send\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../../../@)\" \ - -c \"no neighbor $(../../../../@) capability orf prefix-list send\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../../@)\" \ + -c \"neighbor $VAR(../../../../@) $peer\" \ + -c \"neighbor $VAR(../../../../@) capability orf prefix-list send\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../../../@)\" \ + -c \"no neighbor $VAR(../../../../@) capability orf prefix-list send\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/node.def index 28e4916d..8ea71208 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/node.def @@ -1,22 +1,22 @@ -help: "Originate default route to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set default-originate for neighbor $(../@) in peer-group $(../peer-group/@)" -delete: "touch /tmp/bgp-neighbor-$(../@)-default-originate.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) default-originate \"; \ - if [ -f \"/tmp/bgp-neighbor-$(../@)-default-originate.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-neighbor-$(../@)-default-originate.\\$PPID; \ +help: Originate default route to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set default-originate for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +delete:expression: "touch /tmp/bgp-neighbor-$VAR(../@)-default-originate.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) default-originate \"; \ + if [ -f \"/tmp/bgp-neighbor-$VAR(../@)-default-originate.$PPID\" ]; then \ + rm -rf /tmp/bgp-neighbor-$VAR(../@)-default-originate.$PPID; \ else \ - if [ -n \"$(./route-map/@)\" ]; then \ - cond=\"route-map $(./route-map/@) \" ; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + cond=\"route-map $VAR(./route-map/@) \" ; \ fi ; \ - if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ + if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) default-originate \\$cond\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) default-originate $cond\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/route-map/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/route-map/node.def index 3c067e5b..dd3cc34e 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/route-map/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/default-originate/route-map/node.def @@ -1,4 +1,4 @@ type: txt -help: "Route-map to specify criteria to originate default" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" " ; "route-map $(@) doesn't exist" -commit: $(../../peer-group/) == ""; "You can't set a default-originate route-map for neighbor $(../../@) in peer-group $(../../peer-group/@)" +help: Route-map to specify criteria to originate default +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" " ; "route-map $VAR(@) doesn't exist" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a default-originate route-map for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/description/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/description/node.def index f5ba94f0..7111130e 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/description/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/description/node.def @@ -1,2 +1,2 @@ type: txt -help: "Neighbor specific description" +help: Neighbor specific description diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-capability-negotiation/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-capability-negotiation/node.def index f7099306..9f90c59e 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-capability-negotiation/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-capability-negotiation/node.def @@ -1,13 +1,13 @@ -help: "Do not perform capability negotiation" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Do not perform capability negotiation +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) dont-capability-negotiate \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) dont-capability-negotiate \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) dont-capability-negotiate \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) dont-capability-negotiate \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-connected-check/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-connected-check/node.def index 4d5e6243..a0df6de1 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-connected-check/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-connected-check/node.def @@ -1,13 +1,13 @@ -help: "One hop distant EBGP peer using loopback address" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: One hop distant EBGP peer using loopback address +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) disable-connected-check\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) disable-connected-check \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) disable-connected-check\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) disable-connected-check \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/extended/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/extended/node.def index bc4877c3..02414ea2 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/extended/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/extended/node.def @@ -1,14 +1,14 @@ -help: "Do not send extended community attributes" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set no-send-community for neighbor $(../../@) in peer-group $(../../peer-group/@)" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Do not send extended community attributes +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set no-send-community for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"no neighbor $(../../@) send-community extended\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) send-community extended\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"no neighbor $VAR(../../@) send-community extended\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) send-community extended\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/node.def index 6251cb84..563f3494 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/node.def @@ -1,2 +1,2 @@ -help: "Do not send community attributes to this neighbor" -commit: ($(./extended/) != "") || ($(./standard/) != ""); "You must specify the type of community." +help: Do not send community attributes to this neighbor +commit:expression: ($VAR(./extended/) != "") || ($VAR(./standard/) != ""); "You must specify the type of community." diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/standard/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/standard/node.def index c4f3e2f8..8d2c491b 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/standard/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable-send-community/standard/node.def @@ -1,13 +1,13 @@ -help: "Do not send standard community attributes" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Do not send standard community attributes +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"no neighbor $(../../@) send-community standard\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) send-community standard\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"no neighbor $VAR(../../@) send-community standard\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) send-community standard\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable/node.def index f29ecde9..673af92f 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/disable/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/disable/node.def @@ -1,12 +1,12 @@ -help: "Disable the Address Family for this Neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Disable the Address Family for this Neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"no neighbor $(../@) activate \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) activate \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"no neighbor $VAR(../@) activate \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) activate \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/export/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/export/node.def index e6e33c87..af849ee4 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/export/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/export/node.def @@ -1,16 +1,16 @@ type: u32 -help: "Filter outgoing updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a distribute-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter outgoing updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a distribute-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) distribute-list $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) distribute-list $(@) out\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) distribute-list $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) distribute-list $VAR(@) out\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/import/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/import/node.def index 528c16c6..497830f6 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/import/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/import/node.def @@ -1,16 +1,16 @@ type: u32 -help: "Filter incoming updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a distribute-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter incoming updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a distribute-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) distribute-list $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) distribute-list $(@) in\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) distribute-list $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) distribute-list $VAR(@) in\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/node.def index 8e96b2b5..60273382 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/distribute-list/node.def @@ -1 +1 @@ -help: "Filter updates to/from this neighbor" +help: Filter updates to/from this neighbor diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/ebgp-multihop/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/ebgp-multihop/node.def index 7c2a8478..74478188 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/ebgp-multihop/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/ebgp-multihop/node.def @@ -1,15 +1,15 @@ type: u32 -help: "Allow EBGP neighbors not on directly connected networks" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -syntax: $(@) >=1 && $(@) <= 255; "ebgp-multihop must be between 1 and 255" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Allow EBGP neighbors not on directly connected networks +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +syntax:expression: $VAR(@) >=1 && $VAR(@) <= 255; "ebgp-multihop must be between 1 and 255" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) ebgp-multihop $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) ebgp-multihop \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) ebgp-multihop $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) ebgp-multihop \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/enforce-multihop/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/enforce-multihop/node.def index caae31f3..63365ab1 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/enforce-multihop/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/enforce-multihop/node.def @@ -1,13 +1,13 @@ -help: "Enforce EBGP neighbors perform multihop" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Enforce EBGP neighbors perform multihop +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) enforce-multihop \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) enforce-multihop \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) enforce-multihop \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) enforce-multihop \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/export/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/export/node.def index 620c59a1..1848b34c 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/export/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/export/node.def @@ -1,16 +1,16 @@ type: txt -help: "Filter outgoing updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a filter-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy as-path-list $(@)\" ";"as-path-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter outgoing updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a filter-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy as-path-list $VAR(@)\" ";"as-path-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) filter-list $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) filter-list $(@) out\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) filter-list $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) filter-list $VAR(@) out\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/import/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/import/node.def index 75a56c59..10f09440 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/import/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/import/node.def @@ -1,16 +1,16 @@ type: txt -help: "Filter incoming updates based on AS path" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a filter-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy as-path-list $(@)\" ";"as-path-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter incoming updates based on AS path +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a filter-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy as-path-list $VAR(@)\" ";"as-path-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) filter-list $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) filter-list $(@) in\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) filter-list $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) filter-list $VAR(@) in\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/node.def index 648a1783..b0f70316 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/filter-list/node.def @@ -1 +1 @@ -help: "Establish BGP filters" +help: Establish BGP filters diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/interface/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/interface/node.def index c53cb58c..af446b72 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/interface/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/interface/node.def @@ -1,18 +1,18 @@ type: txt -help: "Interface name" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ]; then \ - echo $(@) doesn\\'t exist on this system ; \ +help: Interface name +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ]; then \ + echo $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) interface $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) interface $(@)\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) interface $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) interface $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/local-as/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/local-as/node.def index 7003828b..ce97c629 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/local-as/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/local-as/node.def @@ -1,6 +1,6 @@ type: u32 -help: "Local AS number" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../peer-group/) == ""; "You can't set a local-as for neighbor $(../@) in peer-group $(../peer-group/@)" -syntax: $(@) >=1 && $(@) <= 4294967294; "local-as must be between 1 and 4294967294" -syntax: $(@) != $(../../../@); "Cannot have local-as same as BGP AS number" +help: Local AS number +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set a local-as for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +syntax:expression: $VAR(@) >=1 && $VAR(@) <= 4294967294; "local-as must be between 1 and 4294967294" +syntax:expression: $VAR(@) != $VAR(../../../@); "Cannot have local-as same as BGP AS number" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/no-prepend/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/no-prepend/node.def index 99b52bdd..5270b67f 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/no-prepend/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/no-prepend/node.def @@ -1 +1 @@ -help: "Do not prepend local-as to updates from EBGP peers" +help: Do not prepend local-as to updates from EBGP peers diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/node.def index aa63bc0b..3ad21f8a 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/local-as/node.def @@ -1,25 +1,25 @@ -help: "Specify a local-as number" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set a local-as for neighbor $(../../@) in peer-group $(../../peer-group/@)" -delete: "touch /tmp/bgp-neighbor-$(../@)-local-as.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) local-as \"; \ - if [ -f \"/tmp/bgp-neighbor-$(../@)-local-as.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-neighbor-$(../@)-local-as.\\$PPID; \ +help: Specify a local-as number +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set a local-as for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +delete:expression: "touch /tmp/bgp-neighbor-$VAR(../@)-local-as.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) local-as \"; \ + if [ -f \"/tmp/bgp-neighbor-$VAR(../@)-local-as.$PPID\" ]; then \ + rm -rf /tmp/bgp-neighbor-$VAR(../@)-local-as.$PPID; \ else \ - if [ -z \"$(./local-as/@)\" ]; then \ + if [ -z \"$VAR(./local-as/@)\" ]; then \ echo You must specify local-as local-as ; \ exit 1 ; \ fi ; \ - if [ -n \"$(./no-prepend/@)\" ]; then \ - cond=\"no-prepend \" ; \ + if [ -n \"$VAR(./no-prepend/@)\" ]; then \ + cond=\"no-prepend \" ; \ fi ; \ - if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ + if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) local-as $(./local-as/@) \\$cond \"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) local-as $VAR(./local-as/@) $cond \"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/maximum-prefix/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/maximum-prefix/node.def index a0f90f79..0d3f920f 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/maximum-prefix/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/maximum-prefix/node.def @@ -1,14 +1,14 @@ type: u32 -help: "Maximum number of prefixes to accept from this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Maximum number of prefixes to accept from this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) maximum-prefix $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) maximum-prefix \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) maximum-prefix $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) maximum-prefix \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/nexthop-self/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/nexthop-self/node.def index ffb33673..4303ec1b 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/nexthop-self/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/nexthop-self/node.def @@ -1,14 +1,14 @@ -help: "Disable the next hop calculation for this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set next-hop-self for neighbor $(../@) in peer-group $(../peer-group/@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Disable the next hop calculation for this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set next-hop-self for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) next-hop-self\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) next-hop-self \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) next-hop-self\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) next-hop-self \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/override-capability/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/override-capability/node.def index af352512..567441ec 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/override-capability/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/override-capability/node.def @@ -1,14 +1,14 @@ -help: "Override capability negotiation result" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../strict-capability/) == ""; "You can't set strict-capability and override-capability for neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Override capability negotiation result +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../strict-capability/) == ""; "You can't set strict-capability and override-capability for neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) override-capability\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) override-capability \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) override-capability\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) override-capability \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/passive/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/passive/node.def index d4c70d55..128a7f70 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/passive/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/passive/node.def @@ -1,13 +1,13 @@ -help: "Don't send open messages to this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Don't send open messages to this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) passive\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) passive \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) passive\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) passive \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/password/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/password/node.def index 00f68338..a45f7294 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/password/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/password/node.def @@ -1,13 +1,13 @@ type: txt -help: "Specify BGP neighbor password" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Specify BGP neighbor password +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) password $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) password\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) password $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) password\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/peer-group/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/peer-group/node.def index 22646f5d..c1b51fd8 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/peer-group/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/peer-group/node.def @@ -1,11 +1,11 @@ type: txt -help: "Member of the peer-group" -syntax: exec "if [ -n \"`echo $(../@) | sed 's/[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}//'`\" ]; then \ +help: Member of the peer-group +syntax:expression: exec "if [ -n \"`echo $VAR(../@) | sed 's/[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}.[0-9]\\{1,3\\}//'`\" ]; then \ exit 1; \ fi; "; "peer-group token may not be specified for a peer-group" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --peergroup=$(@) --as $(../../@) --neighbor $(../@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"protocols bgp $(../../@) neighbor $(@)\" "; "peer-group $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) peer-group $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) peer-group $(@)\" " +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --peergroup=$VAR(@) --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"protocols bgp $VAR(../../@) neighbor $VAR(@)\" "; "peer-group $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) peer-group $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) peer-group $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/port/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/port/node.def index 88322c45..ef388c01 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/port/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/port/node.def @@ -1,14 +1,14 @@ type: u32 -help: "Neighbor's BGP port" -syntax: $(@) >= 1 && $(@) <= 4294967294; "remote-as must be between 1 and 4294967294" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Neighbor's BGP port +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967294; "remote-as must be between 1 and 4294967294" +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) port $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) port \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) port $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) port \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/export/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/export/node.def index 7ec712c2..062a6312 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/export/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/export/node.def @@ -1,16 +1,16 @@ type: txt -help: "Filter outgoing updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a prefix-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter outgoing updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a prefix-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) prefix-list $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) prefix-list $(@) out\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) prefix-list $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) prefix-list $VAR(@) out\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/import/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/import/node.def index c05ebff9..f744b9df 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/import/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/import/node.def @@ -1,16 +1,16 @@ type: txt -help: "Filter incoming updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a prefix-list for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Filter incoming updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a prefix-list for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) prefix-list $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) prefix-list $(@) in\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) prefix-list $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) prefix-list $VAR(@) in\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/node.def index 8e96b2b5..60273382 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/prefix-list/node.def @@ -1 +1 @@ -help: "Filter updates to/from this neighbor" +help: Filter updates to/from this neighbor diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/remote-as/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/remote-as/node.def index ceeba2bd..9e7e7440 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/remote-as/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/remote-as/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Specify BGP neighbor ASN" -syntax: $(@) >= 1 && $(@) <= 4294967294; "remote-as must be between 1 and 4294967294" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) remote-as $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) remote-as $(@)\" " +help: Specify BGP neighbor ASN +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967294; "remote-as must be between 1 and 4294967294" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) remote-as $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) remote-as $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/remove-private-as/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/remove-private-as/node.def index bcca6b3e..70b5f223 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/remove-private-as/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/remove-private-as/node.def @@ -1,14 +1,14 @@ -help: "Remove private AS number from outbound updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set a remove-private-as for neighbor $(../@) in peer-group $(../peer-group/@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Remove private AS number from outbound updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set a remove-private-as for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) remove-private-AS \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) remove-private-AS \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) remove-private-AS \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) remove-private-AS \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/export/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/export/node.def index c3febf9f..51268770 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/export/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/export/node.def @@ -1,16 +1,16 @@ type: txt -help: "Route-map to apply to outgoing updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a route-map for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Route-map to apply to outgoing updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a route-map for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) route-map $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) route-map $(@) out\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) route-map $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) route-map $VAR(@) out\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/import/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/import/node.def index 1d90b721..f59f5e69 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/import/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/import/node.def @@ -1,16 +1,16 @@ type: txt -help: "Route-map to apply to incoming updates" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../../@) --neighbor $(../../@)" -commit: $(../../peer-group/) == ""; "You can't set a route-map for neighbor $(../../@) in peer-group $(../../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Route-map to apply to incoming updates +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../../@) --neighbor $VAR(../../@)" +commit:expression: $VAR(../../peer-group/) == ""; "You can't set a route-map for neighbor $VAR(../../@) in peer-group $VAR(../../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) route-map $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) route-map $(@) in\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) route-map $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) route-map $VAR(@) in\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/node.def index db8271a6..3ad56222 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-map/node.def @@ -1 +1 @@ -help: "Route-map to apply on updates to/from this neighbor" +help: Route-map to apply on updates to/from this neighbor diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-reflector-client/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-reflector-client/node.def index 06b847b2..4079aa80 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-reflector-client/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-reflector-client/node.def @@ -1,15 +1,15 @@ -help: "Configure a neighbor as Route Reflector client" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set route-reflector-client for neighbor $(../@) in peer-group $(../peer-group/@)" -commit: $(../../@) == $(../remote-as/@); "remote-as must equal local-as to be a route-reflector client" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Configure a neighbor as Route Reflector client +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set route-reflector-client for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +commit:expression: $VAR(../../@) == $VAR(../remote-as/@); "remote-as must equal local-as to be a route-reflector client" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) route-reflector-client \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) route-reflector-client \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) route-reflector-client \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) route-reflector-client \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-server-client/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-server-client/node.def index 26308583..a1cf1c32 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/route-server-client/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/route-server-client/node.def @@ -1,14 +1,14 @@ -help: "Configure a neighbor as Route Server client" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set route-server-client for neighbor $(../@) in peer-group $(../peer-group/@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Configure a neighbor as Route Server client +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set route-server-client for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) route-server-client \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) route-server-client \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) route-server-client \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) route-server-client \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/shutdown/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/shutdown/node.def index 1c9b1fbe..8ddee2cf 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/shutdown/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/shutdown/node.def @@ -1,12 +1,12 @@ -help: "Administratively shut down this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Administratively shut down this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) shutdown\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) shutdown\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) shutdown\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) shutdown\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/inbound/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/inbound/node.def index 8780ac0a..1c4adbcf 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/inbound/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/inbound/node.def @@ -1,13 +1,13 @@ -help: "Allow inbound soft reconfiguration for this neighbor" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../../remote-as/@)\" ]; then \ - peer=\"remote-as $(../../remote-as/@)\"; \ +help: Allow inbound soft reconfiguration for this neighbor +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../../remote-as/@)\"; \ else \ - peer=\"peer-group $(../../peer-group/@)\"; \ + peer=\"peer-group $VAR(../../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"neighbor $(../../@) \\$peer\" \ - -c \"neighbor $(../../@) soft-reconfiguration inbound \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no neighbor $(../../@) soft-reconfiguration inbound \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"neighbor $VAR(../../@) $peer\" \ + -c \"neighbor $VAR(../../@) soft-reconfiguration inbound \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no neighbor $VAR(../../@) soft-reconfiguration inbound \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/node.def index 25ab9d17..8cf6600b 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/soft-reconfiguration/node.def @@ -1,2 +1,2 @@ -help: "Per neighbor soft reconfiguration" -commit: $(./inbound/) != ""; "You must specify the type of soft-reconfiguration" +help: Per neighbor soft reconfiguration +commit:expression: $VAR(./inbound/) != ""; "You must specify the type of soft-reconfiguration" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/strict-capability-match/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/strict-capability-match/node.def index 3d389251..695df262 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/strict-capability-match/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/strict-capability-match/node.def @@ -1,13 +1,13 @@ -help: "Strict capability negotiation match" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../override-capability/) == ""; "You can't set strict-capability and override-capability for neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Strict capability negotiation match +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../override-capability/) == ""; "You can't set strict-capability and override-capability for neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) strict-capability-match \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) strict-capability-match \" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) strict-capability-match \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) strict-capability-match \" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/connect/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/connect/node.def index badde464..d2e2533d 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/connect/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/connect/node.def @@ -1,3 +1,3 @@ type: u32 -help: "BGP connect timer" -syntax: $(@) >=0 && $(@) <= 65535; "BGP connect timer must be between 0 and 65535" +help: BGP connect timer +syntax:expression: $VAR(@) >=0 && $VAR(@) <= 65535; "BGP connect timer must be between 0 and 65535" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/holdtime/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/holdtime/node.def index b7da119e..06ebfd09 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/holdtime/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/holdtime/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Holdtime interval" -syntax: $(@) == 0 || ($(@) >= 4 && $(@) <= 65535); "Holdtime interval must be 0 or between 4 and 65535" +help: Holdtime interval +syntax:expression: $VAR(@) == 0 || ($VAR(@) >= 4 && $VAR(@) <= 65535); "Holdtime interval must be 0 or between 4 and 65535" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/keepalive/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/keepalive/node.def index 59067fdc..3d68ba94 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/keepalive/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/keepalive/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Keepalive interval" -syntax: $(@) >= 1 && $(@) <= 65535; "Keepalive interval must be between 1 and 65535" +help: Keepalive interval +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Keepalive interval must be between 1 and 65535" diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/node.def index 1753510f..8515b9dc 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/timers/node.def @@ -1,27 +1,27 @@ -help: "BGP per neighbor timers" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set timers for neighbor $(../@) in peer-group $(../peer-group/@)" -delete: "touch /tmp/bgp-neighbor-$(../@)-timers.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) timers \"; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) timers connect \"; \ - if [ -f \"/tmp/bgp-neighbor-$(../@)-timers.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-neighbor-$(../@)-timers.\\$PPID; \ +help: BGP per neighbor timers +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set timers for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +delete:expression: "touch /tmp/bgp-neighbor-$VAR(../@)-timers.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) timers \"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) timers connect \"; \ + if [ -f \"/tmp/bgp-neighbor-$VAR(../@)-timers.$PPID\" ]; then \ + rm -rf /tmp/bgp-neighbor-$VAR(../@)-timers.$PPID; \ else \ - if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ + if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - if [ -n \"$(./connect/@)\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) timers connect $(./connect/@)\" ; \ + if [ -n \"$VAR(./connect/@)\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) timers connect $VAR(./connect/@)\" ; \ fi ; \ - if [ -n \"$(./keepalive/@)\" ] || [ -n \"$(./holdtime/@)\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) timers $(./keepalive/@) $(./holdtime/@)\"; \ + if [ -n \"$VAR(./keepalive/@)\" ] || [ -n \"$VAR(./holdtime/@)\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) timers $VAR(./keepalive/@) $VAR(./holdtime/@)\"; \ fi ; \ fi; " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/unsuppress-map/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/unsuppress-map/node.def index f228b80b..9251c28a 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/unsuppress-map/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/unsuppress-map/node.def @@ -1,15 +1,15 @@ type: txt -help: "Route-map to selectively unsuppress suppressed routes" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -commit: $(../peer-group/) == ""; "You can't set an unsuppress-map for neighbor $(../@) in peer-group $(../peer-group/@)" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Route-map to selectively unsuppress suppressed routes +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +commit:expression: $VAR(../peer-group/) == ""; "You can't set an unsuppress-map for neighbor $VAR(../@) in peer-group $VAR(../peer-group/@)" +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) unsuppress-map $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) unsuppress-map $(@)\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) unsuppress-map $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) unsuppress-map $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/update-source/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/update-source/node.def index 17f68349..afa51402 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/update-source/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/update-source/node.def @@ -1,18 +1,18 @@ type: txt -help: "Source of routing updates" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ]; then \ - echo $(@) doesn\\'t exist on this system ; \ +help: Source of routing updates +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ]; then \ + echo $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) update-source $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) update-source $(@)\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) update-source $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) update-source $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/neighbor/node.tag/weight/node.def b/templates/protocols/bgp/node.tag/neighbor/node.tag/weight/node.def index 215d741f..3ca1bd6c 100644 --- a/templates/protocols/bgp/node.tag/neighbor/node.tag/weight/node.def +++ b/templates/protocols/bgp/node.tag/neighbor/node.tag/weight/node.def @@ -1,14 +1,14 @@ type: u32 -help: "Set default weight for routes from this neighbor" -syntax: $(@) >= 1 && $(@) <= 65535; "weight must be between 1 and 65535" -commit: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $(../../@) --neighbor $(../@)" -update: "if [ -n \"$(../remote-as/@)\" ]; then \ - peer=\"remote-as $(../remote-as/@)\"; \ +help: Set default weight for routes from this neighbor +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "weight must be between 1 and 65535" +commit:expression: exec "/opt/vyatta/sbin/vyatta-bgp.pl --check-as --as $VAR(../../@) --neighbor $VAR(../@)" +update:expression: "if [ -n \"$VAR(../remote-as/@)\" ]; then \ + peer=\"remote-as $VAR(../remote-as/@)\"; \ else \ - peer=\"peer-group $(../peer-group/@)\"; \ + peer=\"peer-group $VAR(../peer-group/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"neighbor $(../@) \\$peer\" \ - -c \"neighbor $(../@) weight $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"no neighbor $(../@) weight $(@)\" " + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"neighbor $VAR(../@) $peer\" \ + -c \"neighbor $VAR(../@) weight $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"no neighbor $VAR(../@) weight $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/network/node.def b/templates/protocols/bgp/node.tag/network/node.def index 5898708d..5299d456 100644 --- a/templates/protocols/bgp/node.tag/network/node.def +++ b/templates/protocols/bgp/node.tag/network/node.def @@ -1,20 +1,20 @@ tag: type: ipv4net -help: "Specify a network to announce via BGP" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -commit: !($(./backdoor/) != "" && $(./route-map/) != ""); "May specify route-map or backdoor but not both" -delete: "touch /tmp/`echo $(@) | sed 's!/!!'`.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $(../@)\" \ - -c \"no network $(@)\"; \ - if [ -f \"/tmp/`echo $(@) | sed 's!/!!'`.\\$PPID\" ]; then \ - rm -rf /tmp/`echo $(@) | sed 's!/!!'`.\\$PPID; \ +help: Specify a network to announce via BGP +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +commit:expression: !($VAR(./backdoor/) != "" && $VAR(./route-map/) != ""); "May specify route-map or backdoor but not both" +delete:expression: "touch /tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -noerr -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ + -c \"no network $VAR(@)\"; \ + if [ -f \"/tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID\" ]; then \ + rm -rf /tmp/`echo $VAR(@) | sed 's!/!!'`.$PPID; \ else \ - if [ -n \"$(./backdoor/)\" ]; then \ + if [ -n \"$VAR(./backdoor/)\" ]; then \ COND=\"backdoor\"; \ fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" \ - -c \"network $(@) \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ + -c \"network $VAR(@) $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/network/node.tag/backdoor/node.def b/templates/protocols/bgp/node.tag/network/node.tag/backdoor/node.def index eb1b3ab5..b7dc6950 100644 --- a/templates/protocols/bgp/node.tag/network/node.tag/backdoor/node.def +++ b/templates/protocols/bgp/node.tag/network/node.tag/backdoor/node.def @@ -1 +1 @@ -help: "Specify a BGP backdoor route" +help: Specify a BGP backdoor route diff --git a/templates/protocols/bgp/node.tag/network/node.tag/route-map/node.def b/templates/protocols/bgp/node.tag/network/node.tag/route-map/node.def index a0f6f5fa..7a19c2e4 100644 --- a/templates/protocols/bgp/node.tag/network/node.tag/route-map/node.def +++ b/templates/protocols/bgp/node.tag/network/node.tag/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route-map to modify the attributes" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route-map to modify the attributes +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/parameters/always-compare-med/node.def b/templates/protocols/bgp/node.tag/parameters/always-compare-med/node.def index bf0959c9..37e251af 100644 --- a/templates/protocols/bgp/node.tag/parameters/always-compare-med/node.def +++ b/templates/protocols/bgp/node.tag/parameters/always-compare-med/node.def @@ -1,5 +1,5 @@ -help: "Allow comparing MED from different neighbors" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Allow comparing MED from different neighbors +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp always-compare-med\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp always-compare-med\" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/confed/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/confed/node.def index d5e39a06..c3ebac90 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/confed/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/confed/node.def @@ -1,6 +1,6 @@ -help: "Compare path lengths including confederation sets & sequences in selecting a route" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +help: Compare path lengths including confederation sets & sequences in selecting a route +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"bgp bestpath as-path confed \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"no bgp bestpath as-path confed \" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/ignore/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/ignore/node.def index 46385534..7959a950 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/ignore/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/ignore/node.def @@ -1,5 +1,5 @@ -help: "Ignore as-path length in selecting a route" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +help: Ignore as-path length in selecting a route +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"bgp bestpath as-path ignore \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"no bgp bestpath as-path ignore \" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/node.def index 72b50839..dda0fc5f 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/as-path/node.def @@ -1 +1 @@ -help: "AS-path attribute" +help: AS-path attribute diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/compare-routerid/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/compare-routerid/node.def index ba6a7ab4..2c34a4b6 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/compare-routerid/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/compare-routerid/node.def @@ -1,6 +1,6 @@ -help: "Compare router-id for identical EBGP paths" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Compare router-id for identical EBGP paths +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"bgp bestpath compare-routerid \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp bestpath compare-routerid \" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/med/confed/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/med/confed/node.def index 7de7aa6c..ec31b51c 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/med/confed/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/med/confed/node.def @@ -1,6 +1,6 @@ -help: "Compare MED among confederation paths" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +help: Compare MED among confederation paths +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"bgp bestpath med confed \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"no bgp bestpath med confed \" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/med/missing-as-worst/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/med/missing-as-worst/node.def index 7abff30d..9eb5b558 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/med/missing-as-worst/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/med/missing-as-worst/node.def @@ -1,6 +1,6 @@ -help: "Treat missing MED as the least preferred one" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +help: Treat missing MED as the least preferred one +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"bgp bestpath med missing-as-worst \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../../@)\" \ -c \"no bgp bestpath med missing-as-worst \" " diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/med/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/med/node.def index 350270bb..088a9331 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/med/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/med/node.def @@ -1 +1 @@ -help: "MED attribute" +help: MED attribute diff --git a/templates/protocols/bgp/node.tag/parameters/bestpath/node.def b/templates/protocols/bgp/node.tag/parameters/bestpath/node.def index b4a1bbe7..178e4573 100644 --- a/templates/protocols/bgp/node.tag/parameters/bestpath/node.def +++ b/templates/protocols/bgp/node.tag/parameters/bestpath/node.def @@ -1 +1 @@ -help: "Change the default bestpath selection" +help: Change the default bestpath selection diff --git a/templates/protocols/bgp/node.tag/parameters/cluster-id/node.def b/templates/protocols/bgp/node.tag/parameters/cluster-id/node.def index c29c5c23..dcc764ed 100644 --- a/templates/protocols/bgp/node.tag/parameters/cluster-id/node.def +++ b/templates/protocols/bgp/node.tag/parameters/cluster-id/node.def @@ -1,6 +1,6 @@ type: ipv4 -help: "Configure route-reflector cluster-id\n" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"bgp cluster-id $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Configure route-reflector cluster-id\n +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"bgp cluster-id $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp cluster-id \" " diff --git a/templates/protocols/bgp/node.tag/parameters/confederation/identifier/node.def b/templates/protocols/bgp/node.tag/parameters/confederation/identifier/node.def index c30eebd7..2d862c46 100644 --- a/templates/protocols/bgp/node.tag/parameters/confederation/identifier/node.def +++ b/templates/protocols/bgp/node.tag/parameters/confederation/identifier/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Configure confederation AS id" -syntax: $(@) >= 1 && $(@) <= 4294967294; "confederation AS id must be between 1 and 4294967294" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"bgp confederation identifier $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Configure confederation AS id +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967294; "confederation AS id must be between 1 and 4294967294" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"bgp confederation identifier $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp confederation identifier \" " diff --git a/templates/protocols/bgp/node.tag/parameters/confederation/node.def b/templates/protocols/bgp/node.tag/parameters/confederation/node.def index 272c946c..4933aeab 100644 --- a/templates/protocols/bgp/node.tag/parameters/confederation/node.def +++ b/templates/protocols/bgp/node.tag/parameters/confederation/node.def @@ -1 +1 @@ -help: "AS confederation parameters" +help: AS confederation parameters diff --git a/templates/protocols/bgp/node.tag/parameters/confederation/peers/node.def b/templates/protocols/bgp/node.tag/parameters/confederation/peers/node.def index 0b8d04ed..c32b767f 100644 --- a/templates/protocols/bgp/node.tag/parameters/confederation/peers/node.def +++ b/templates/protocols/bgp/node.tag/parameters/confederation/peers/node.def @@ -1,8 +1,8 @@ multi: type: u32 -help: "Peer ASs in BGP confederation" -syntax: $(@) >= 1 && $(@) <= 4294967294; "confederation AS id must be between 1 and 4294967294" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"bgp confederation peers $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"no bgp confederation peers $(@)\" " +help: Peer ASs in BGP confederation +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967294; "confederation AS id must be between 1 and 4294967294" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"bgp confederation peers $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"no bgp confederation peers $VAR(@)\" " diff --git a/templates/protocols/bgp/node.tag/parameters/dampening/half-life/node.def b/templates/protocols/bgp/node.tag/parameters/dampening/half-life/node.def index aa710acf..43839b82 100644 --- a/templates/protocols/bgp/node.tag/parameters/dampening/half-life/node.def +++ b/templates/protocols/bgp/node.tag/parameters/dampening/half-life/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Half-life time for the penalty" -syntax: $(@) >= 1 && $(@) <= 45; "Half-life penalty must be between 1 and 45" +help: Half-life time for the penalty +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 45; "Half-life penalty must be between 1 and 45" diff --git a/templates/protocols/bgp/node.tag/parameters/dampening/max-suppress-time/node.def b/templates/protocols/bgp/node.tag/parameters/dampening/max-suppress-time/node.def index a4f59b8f..5c77e861 100644 --- a/templates/protocols/bgp/node.tag/parameters/dampening/max-suppress-time/node.def +++ b/templates/protocols/bgp/node.tag/parameters/dampening/max-suppress-time/node.def @@ -1,5 +1,5 @@ type: u32 -help: "Maximum duration to suppress a stable route" -syntax: $(@) >= 1 && $(@) <= 255; "Max-suppress-time must be between 1 and 255" -commit: $(../re-use/) != ""; "Re-use value must be set" -commit: $(../start-suppress-time/) != ""; "Start-suppress-time must be set" +help: Maximum duration to suppress a stable route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Max-suppress-time must be between 1 and 255" +commit:expression: $VAR(../re-use/) != ""; "Re-use value must be set" +commit:expression: $VAR(../start-suppress-time/) != ""; "Start-suppress-time must be set" diff --git a/templates/protocols/bgp/node.tag/parameters/dampening/node.def b/templates/protocols/bgp/node.tag/parameters/dampening/node.def index 487725dc..8d15aadc 100644 --- a/templates/protocols/bgp/node.tag/parameters/dampening/node.def +++ b/templates/protocols/bgp/node.tag/parameters/dampening/node.def @@ -1,12 +1,12 @@ -help: "Enable route-flap dampening" -delete: "touch /tmp/bgp-dampening.\\$PPID" -end: "sh -c \" - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \\\"configure terminal\\\" -c \\\"router bgp $(../../@)\\\" \ +help: Enable route-flap dampening +delete:expression: "touch /tmp/bgp-dampening.$PPID" +end:expression: "sh -c \" + ${vyatta_sbindir}/vyatta-vtysh.pl -c \\\"configure terminal\\\" -c \\\"router bgp $VAR(../../@)\\\" \ -c \\\"no bgp dampening\\\" ; \ - if [ -f \\\"/tmp/bgp-dampening.\\\\$PPID\\\" ]; then \ - rm -f \\\"/tmp/bgp-dampening.\\\\$PPID\\\" ; \ + if [ -f \\\"/tmp/bgp-dampening.$PPID\\\" ]; then \ + rm -f \\\"/tmp/bgp-dampening.$PPID\\\" ; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \\\"configure terminal\\\" -c \\\"router bgp $(../../@)\\\" \ - -c \\\"bgp dampening $(./half-life/@) $(./re-use/@) $(./start-suppress-time/@) $(./max-suppress-time/@)\\\" ; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \\\"configure terminal\\\" -c \\\"router bgp $VAR(../../@)\\\" \ + -c \\\"bgp dampening $VAR(./half-life/@) $VAR(./re-use/@) $VAR(./start-suppress-time/@) $VAR(./max-suppress-time/@)\\\" ; \ fi ; \ \" " diff --git a/templates/protocols/bgp/node.tag/parameters/dampening/re-use/node.def b/templates/protocols/bgp/node.tag/parameters/dampening/re-use/node.def index 83b3e246..e9e9af8f 100644 --- a/templates/protocols/bgp/node.tag/parameters/dampening/re-use/node.def +++ b/templates/protocols/bgp/node.tag/parameters/dampening/re-use/node.def @@ -1,5 +1,5 @@ type: u32 -help: "Value to start reusing a route" -syntax: $(@) >= 1 && $(@) <= 20000; "Re-use value must be between 1 and 20000" -commit: $(../start-suppress-time/) != ""; "Start-suppress-time must be set" -commit: $(../max-suppress-time/) != ""; "Max-suppress-time must be set" +help: Value to start reusing a route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 20000; "Re-use value must be between 1 and 20000" +commit:expression: $VAR(../start-suppress-time/) != ""; "Start-suppress-time must be set" +commit:expression: $VAR(../max-suppress-time/) != ""; "Max-suppress-time must be set" diff --git a/templates/protocols/bgp/node.tag/parameters/dampening/start-suppress-time/node.def b/templates/protocols/bgp/node.tag/parameters/dampening/start-suppress-time/node.def index 17d5a67a..4e79cf61 100644 --- a/templates/protocols/bgp/node.tag/parameters/dampening/start-suppress-time/node.def +++ b/templates/protocols/bgp/node.tag/parameters/dampening/start-suppress-time/node.def @@ -1,5 +1,5 @@ type: u32 -help: "Value to start suppressing a route" -syntax: $(@) >= 1 && $(@) <= 20000; "Start-suppress-time must be between 1 and 20000" -commit: $(../re-use/) != ""; "Re-use value must be set" -commit: $(../max-suppress-time/) != ""; "Max-suppress-time must be set" +help: Value to start suppressing a route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 20000; "Start-suppress-time must be between 1 and 20000" +commit:expression: $VAR(../re-use/) != ""; "Re-use value must be set" +commit:expression: $VAR(../max-suppress-time/) != ""; "Max-suppress-time must be set" diff --git a/templates/protocols/bgp/node.tag/parameters/default/local-pref/node.def b/templates/protocols/bgp/node.tag/parameters/default/local-pref/node.def index 0b2f4501..e9e16e73 100644 --- a/templates/protocols/bgp/node.tag/parameters/default/local-pref/node.def +++ b/templates/protocols/bgp/node.tag/parameters/default/local-pref/node.def @@ -1,6 +1,6 @@ type: u32 -help: "Local preference (higher=more preferred)" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"bgp default local-preference $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Local preference (higher=more preferred) +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"bgp default local-preference $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp default local-preference\" " diff --git a/templates/protocols/bgp/node.tag/parameters/default/no-ipv4-unicast/node.def b/templates/protocols/bgp/node.tag/parameters/default/no-ipv4-unicast/node.def index cb184c4b..184dfcb7 100644 --- a/templates/protocols/bgp/node.tag/parameters/default/no-ipv4-unicast/node.def +++ b/templates/protocols/bgp/node.tag/parameters/default/no-ipv4-unicast/node.def @@ -1,5 +1,5 @@ -help: "Deactivate IPv4 unicast for a peer by default" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Deactivate IPv4 unicast for a peer by default +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp default ipv4-unicast\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"bgp default ipv4-unicast\" " diff --git a/templates/protocols/bgp/node.tag/parameters/default/node.def b/templates/protocols/bgp/node.tag/parameters/default/node.def index f1c90ec3..5f2ebba5 100644 --- a/templates/protocols/bgp/node.tag/parameters/default/node.def +++ b/templates/protocols/bgp/node.tag/parameters/default/node.def @@ -1 +1 @@ -help: "Configure BGP defaults" +help: Configure BGP defaults diff --git a/templates/protocols/bgp/node.tag/parameters/deterministic-med/node.def b/templates/protocols/bgp/node.tag/parameters/deterministic-med/node.def index e74fd24f..e7b0e50f 100644 --- a/templates/protocols/bgp/node.tag/parameters/deterministic-med/node.def +++ b/templates/protocols/bgp/node.tag/parameters/deterministic-med/node.def @@ -1,5 +1,5 @@ -help: "Pick the best-MED path among paths advertised from the neighboring AS" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Pick the best-MED path among paths advertised from the neighboring AS +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp deterministic-med \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp deterministic-med \" " diff --git a/templates/protocols/bgp/node.tag/parameters/enforce-first-as/node.def b/templates/protocols/bgp/node.tag/parameters/enforce-first-as/node.def index f08645a7..eff66372 100644 --- a/templates/protocols/bgp/node.tag/parameters/enforce-first-as/node.def +++ b/templates/protocols/bgp/node.tag/parameters/enforce-first-as/node.def @@ -1,5 +1,5 @@ -help: "Enforce the first AS for EBGP routes" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Enforce the first AS for EBGP routes +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp enforce-first-as \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp enforce-first-as \" " diff --git a/templates/protocols/bgp/node.tag/parameters/graceful-restart/node.def b/templates/protocols/bgp/node.tag/parameters/graceful-restart/node.def index 1e849462..ef9d8f38 100644 --- a/templates/protocols/bgp/node.tag/parameters/graceful-restart/node.def +++ b/templates/protocols/bgp/node.tag/parameters/graceful-restart/node.def @@ -1 +1 @@ -help: "Graceful restart capability parameters" +help: Graceful restart capability parameters diff --git a/templates/protocols/bgp/node.tag/parameters/graceful-restart/stalepath-time/node.def b/templates/protocols/bgp/node.tag/parameters/graceful-restart/stalepath-time/node.def index e4e5ae3a..763dc4a9 100644 --- a/templates/protocols/bgp/node.tag/parameters/graceful-restart/stalepath-time/node.def +++ b/templates/protocols/bgp/node.tag/parameters/graceful-restart/stalepath-time/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Set the max time in seconds to hold onto restarting peer's stale paths" -syntax: $(@) >= 1 && $(@) <= 3600; "stalepath-time must be between 1 and 3600" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ - -c \"bgp graceful-restart stalepath-time $(@) \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Set the max time in seconds to hold onto restarting peer's stale paths +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 3600; "stalepath-time must be between 1 and 3600" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ + -c \"bgp graceful-restart stalepath-time $VAR(@) \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp graceful-restart stalepath-time \" " diff --git a/templates/protocols/bgp/node.tag/parameters/log-neighbor-changes/node.def b/templates/protocols/bgp/node.tag/parameters/log-neighbor-changes/node.def index eb9184a4..d88b8de1 100644 --- a/templates/protocols/bgp/node.tag/parameters/log-neighbor-changes/node.def +++ b/templates/protocols/bgp/node.tag/parameters/log-neighbor-changes/node.def @@ -1,5 +1,5 @@ -help: "Log neighbor up/down and reset reason" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Log neighbor up/down and reset reason +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp log-neighbor-changes \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp log-neighbor-changes \" " diff --git a/templates/protocols/bgp/node.tag/parameters/network/import-check/node.def b/templates/protocols/bgp/node.tag/parameters/network/import-check/node.def index 65d058a4..887eceaf 100644 --- a/templates/protocols/bgp/node.tag/parameters/network/import-check/node.def +++ b/templates/protocols/bgp/node.tag/parameters/network/import-check/node.def @@ -1,5 +1,5 @@ -help: "Check BGP network route exists in IGP" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +help: Check BGP network route exists in IGP +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"bgp network import-check \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../../@)\" \ -c \"no bgp network import-check \" " diff --git a/templates/protocols/bgp/node.tag/parameters/network/node.def b/templates/protocols/bgp/node.tag/parameters/network/node.def index 2db2693f..afc062e7 100644 --- a/templates/protocols/bgp/node.tag/parameters/network/node.def +++ b/templates/protocols/bgp/node.tag/parameters/network/node.def @@ -1 +1 @@ -help: "Network parameter options" +help: Network parameter options diff --git a/templates/protocols/bgp/node.tag/parameters/no-client-to-client-reflection/node.def b/templates/protocols/bgp/node.tag/parameters/no-client-to-client-reflection/node.def index 5121991f..33ad9a29 100644 --- a/templates/protocols/bgp/node.tag/parameters/no-client-to-client-reflection/node.def +++ b/templates/protocols/bgp/node.tag/parameters/no-client-to-client-reflection/node.def @@ -1,5 +1,5 @@ -help: "Disable client to client route reflection" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Disable client to client route reflection +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp client-to-client reflection \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp client-to-client reflection \" " diff --git a/templates/protocols/bgp/node.tag/parameters/no-fast-external-failover/node.def b/templates/protocols/bgp/node.tag/parameters/no-fast-external-failover/node.def index d25928d8..88eef57c 100644 --- a/templates/protocols/bgp/node.tag/parameters/no-fast-external-failover/node.def +++ b/templates/protocols/bgp/node.tag/parameters/no-fast-external-failover/node.def @@ -1,5 +1,5 @@ -help: "Immediately reset session if a link to a directly connected external peer goes down" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Immediately reset session if a link to a directly connected external peer goes down +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp fast-external-failover \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"bgp fast-external-failover \" " diff --git a/templates/protocols/bgp/node.tag/parameters/node.def b/templates/protocols/bgp/node.tag/parameters/node.def index b23668f8..cd6b28ce 100644 --- a/templates/protocols/bgp/node.tag/parameters/node.def +++ b/templates/protocols/bgp/node.tag/parameters/node.def @@ -1 +1 @@ -help: "Configure BGP parameters" +help: Configure BGP parameters diff --git a/templates/protocols/bgp/node.tag/parameters/router-id/node.def b/templates/protocols/bgp/node.tag/parameters/router-id/node.def index dcba9f4f..6e9de2dc 100644 --- a/templates/protocols/bgp/node.tag/parameters/router-id/node.def +++ b/templates/protocols/bgp/node.tag/parameters/router-id/node.def @@ -1,6 +1,6 @@ type: ipv4 -help: "Override configured router identifier" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"bgp router-id $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Override configured router identifier +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"bgp router-id $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp router-id \" " diff --git a/templates/protocols/bgp/node.tag/parameters/scan-time/node.def b/templates/protocols/bgp/node.tag/parameters/scan-time/node.def index cfb0ef23..5fb71d57 100644 --- a/templates/protocols/bgp/node.tag/parameters/scan-time/node.def +++ b/templates/protocols/bgp/node.tag/parameters/scan-time/node.def @@ -1,7 +1,7 @@ type: u32 -syntax: $(@) >= 5 && $(@) <= 60; "scan-time must be between 5 and 60 seconds" -help: "Configure background scanner interval" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"bgp scan-time $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 60; "scan-time must be between 5 and 60 seconds" +help: Configure background scanner interval +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"bgp scan-time $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no bgp scan-time \" " diff --git a/templates/protocols/bgp/node.tag/redistribute/connected/metric/node.def b/templates/protocols/bgp/node.tag/redistribute/connected/metric/node.def index 984a7064..43f1ffff 100644 --- a/templates/protocols/bgp/node.tag/redistribute/connected/metric/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/connected/metric/node.def @@ -1,2 +1,2 @@ type: u32 -help: "Metric for redistributed routes" +help: Metric for redistributed routes diff --git a/templates/protocols/bgp/node.tag/redistribute/connected/node.def b/templates/protocols/bgp/node.tag/redistribute/connected/node.def index 1e78e6bb..5bdf3b2f 100644 --- a/templates/protocols/bgp/node.tag/redistribute/connected/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/connected/node.def @@ -1,16 +1,16 @@ -help: "Redistribute connected routes" -delete: "touch /tmp/bgp-redist-connected.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Redistribute connected routes +delete:expression: "touch /tmp/bgp-redist-connected.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no redistribute connected \"; \ - if [ -f \"/tmp/bgp-redist-connected.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-redist-connected.\\$PPID; \ + if [ -f \"/tmp/bgp-redist-connected.$PPID\" ]; then \ + rm -rf /tmp/bgp-redist-connected.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"redistribute connected \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"redistribute connected $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/redistribute/connected/route-map/node.def b/templates/protocols/bgp/node.tag/redistribute/connected/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/bgp/node.tag/redistribute/connected/route-map/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/connected/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/redistribute/kernel/metric/node.def b/templates/protocols/bgp/node.tag/redistribute/kernel/metric/node.def index 984a7064..43f1ffff 100644 --- a/templates/protocols/bgp/node.tag/redistribute/kernel/metric/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/kernel/metric/node.def @@ -1,2 +1,2 @@ type: u32 -help: "Metric for redistributed routes" +help: Metric for redistributed routes diff --git a/templates/protocols/bgp/node.tag/redistribute/kernel/node.def b/templates/protocols/bgp/node.tag/redistribute/kernel/node.def index 57e0531a..479114fd 100644 --- a/templates/protocols/bgp/node.tag/redistribute/kernel/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/kernel/node.def @@ -1,16 +1,16 @@ -help: "Redistribute kernel routes" -delete: "touch /tmp/bgp-redist-kernel.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Redistribute kernel routes +delete:expression: "touch /tmp/bgp-redist-kernel.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no redistribute kernel \"; \ - if [ -f \"/tmp/bgp-redist-kernel.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-redist-kernel.\\$PPID; \ + if [ -f \"/tmp/bgp-redist-kernel.$PPID\" ]; then \ + rm -rf /tmp/bgp-redist-kernel.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"redistribute kernel \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"redistribute kernel $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/redistribute/kernel/route-map/node.def b/templates/protocols/bgp/node.tag/redistribute/kernel/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/bgp/node.tag/redistribute/kernel/route-map/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/kernel/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/redistribute/node.def b/templates/protocols/bgp/node.tag/redistribute/node.def index e46c9122..00eefa88 100644 --- a/templates/protocols/bgp/node.tag/redistribute/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/node.def @@ -1 +1 @@ -help: "Redistribute information from another routing protocol" +help: Redistribute information from another routing protocol diff --git a/templates/protocols/bgp/node.tag/redistribute/ospf/metric/node.def b/templates/protocols/bgp/node.tag/redistribute/ospf/metric/node.def index 984a7064..43f1ffff 100644 --- a/templates/protocols/bgp/node.tag/redistribute/ospf/metric/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/ospf/metric/node.def @@ -1,2 +1,2 @@ type: u32 -help: "Metric for redistributed routes" +help: Metric for redistributed routes diff --git a/templates/protocols/bgp/node.tag/redistribute/ospf/node.def b/templates/protocols/bgp/node.tag/redistribute/ospf/node.def index 445b9869..f1a894a7 100644 --- a/templates/protocols/bgp/node.tag/redistribute/ospf/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/ospf/node.def @@ -1,16 +1,16 @@ -help: "Redistribute OSPF routes" -delete: "touch /tmp/bgp-redist-ospf.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Redistribute OSPF routes +delete:expression: "touch /tmp/bgp-redist-ospf.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no redistribute ospf \"; \ - if [ -f \"/tmp/bgp-redist-ospf.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-redist-ospf.\\$PPID; \ + if [ -f \"/tmp/bgp-redist-ospf.$PPID\" ]; then \ + rm -rf /tmp/bgp-redist-ospf.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"redistribute ospf \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"redistribute ospf $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/redistribute/ospf/route-map/node.def b/templates/protocols/bgp/node.tag/redistribute/ospf/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/bgp/node.tag/redistribute/ospf/route-map/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/ospf/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/redistribute/rip/metric/node.def b/templates/protocols/bgp/node.tag/redistribute/rip/metric/node.def index 984a7064..43f1ffff 100644 --- a/templates/protocols/bgp/node.tag/redistribute/rip/metric/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/rip/metric/node.def @@ -1,2 +1,2 @@ type: u32 -help: "Metric for redistributed routes" +help: Metric for redistributed routes diff --git a/templates/protocols/bgp/node.tag/redistribute/rip/node.def b/templates/protocols/bgp/node.tag/redistribute/rip/node.def index c2a4b239..f67cfdc6 100644 --- a/templates/protocols/bgp/node.tag/redistribute/rip/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/rip/node.def @@ -1,16 +1,16 @@ -help: "Redistribute RIP routes" -delete: "touch /tmp/bgp-redist-rip.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Redistribute RIP routes +delete:expression: "touch /tmp/bgp-redist-rip.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no redistribute rip \"; \ - if [ -f \"/tmp/bgp-redist-rip.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-redist-rip.\\$PPID; \ + if [ -f \"/tmp/bgp-redist-rip.$PPID\" ]; then \ + rm -rf /tmp/bgp-redist-rip.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"redistribute rip \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"redistribute rip $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/redistribute/rip/route-map/node.def b/templates/protocols/bgp/node.tag/redistribute/rip/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/bgp/node.tag/redistribute/rip/route-map/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/rip/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/redistribute/static/metric/node.def b/templates/protocols/bgp/node.tag/redistribute/static/metric/node.def index 984a7064..43f1ffff 100644 --- a/templates/protocols/bgp/node.tag/redistribute/static/metric/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/static/metric/node.def @@ -1,2 +1,2 @@ type: u32 -help: "Metric for redistributed routes" +help: Metric for redistributed routes diff --git a/templates/protocols/bgp/node.tag/redistribute/static/node.def b/templates/protocols/bgp/node.tag/redistribute/static/node.def index ebf8bc87..d34e30ad 100644 --- a/templates/protocols/bgp/node.tag/redistribute/static/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/static/node.def @@ -1,16 +1,16 @@ -help: "Redistribute static routes" -delete: "touch /tmp/bgp-redist-static.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ +help: Redistribute static routes +delete:expression: "touch /tmp/bgp-redist-static.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ -c \"no redistribute static \"; \ - if [ -f \"/tmp/bgp-redist-static.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-redist-static.\\$PPID; \ + if [ -f \"/tmp/bgp-redist-static.$PPID\" ]; then \ + rm -rf /tmp/bgp-redist-static.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../../@)\" \ - -c \"redistribute static \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../../@)\" \ + -c \"redistribute static $COND\"; \ fi; " diff --git a/templates/protocols/bgp/node.tag/redistribute/static/route-map/node.def b/templates/protocols/bgp/node.tag/redistribute/static/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/bgp/node.tag/redistribute/static/route-map/node.def +++ b/templates/protocols/bgp/node.tag/redistribute/static/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/bgp/node.tag/timers/holdtime/node.def b/templates/protocols/bgp/node.tag/timers/holdtime/node.def index b7da119e..06ebfd09 100644 --- a/templates/protocols/bgp/node.tag/timers/holdtime/node.def +++ b/templates/protocols/bgp/node.tag/timers/holdtime/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Holdtime interval" -syntax: $(@) == 0 || ($(@) >= 4 && $(@) <= 65535); "Holdtime interval must be 0 or between 4 and 65535" +help: Holdtime interval +syntax:expression: $VAR(@) == 0 || ($VAR(@) >= 4 && $VAR(@) <= 65535); "Holdtime interval must be 0 or between 4 and 65535" diff --git a/templates/protocols/bgp/node.tag/timers/keepalive/node.def b/templates/protocols/bgp/node.tag/timers/keepalive/node.def index 59067fdc..3d68ba94 100644 --- a/templates/protocols/bgp/node.tag/timers/keepalive/node.def +++ b/templates/protocols/bgp/node.tag/timers/keepalive/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Keepalive interval" -syntax: $(@) >= 1 && $(@) <= 65535; "Keepalive interval must be between 1 and 65535" +help: Keepalive interval +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Keepalive interval must be between 1 and 65535" diff --git a/templates/protocols/bgp/node.tag/timers/node.def b/templates/protocols/bgp/node.tag/timers/node.def index 51475580..9fcace77 100644 --- a/templates/protocols/bgp/node.tag/timers/node.def +++ b/templates/protocols/bgp/node.tag/timers/node.def @@ -1,12 +1,12 @@ -help: "Adjust routing timers" -commit: $(./keepalive/) != ""; "You must set a keepalive interval" -commit: $(./holdtime/) != ""; "You must set a holdtime interval" -delete: "touch /tmp/bgp-timers.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" \ +help: Adjust routing timers +commit:expression: $VAR(./keepalive/) != ""; "You must set a keepalive interval" +commit:expression: $VAR(./holdtime/) != ""; "You must set a holdtime interval" +delete:expression: "touch /tmp/bgp-timers.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ -c \"no timers bgp\"; \ - if [ -f \"/tmp/bgp-timers.\\$PPID\" ]; then \ - rm -rf /tmp/bgp-timers.\\$PPID; \ + if [ -f \"/tmp/bgp-timers.$PPID\" ]; then \ + rm -rf /tmp/bgp-timers.$PPID; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $(../@)\" \ - -c \"timers bgp $(./keepalive/@) $(./holdtime/@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router bgp $VAR(../@)\" \ + -c \"timers bgp $VAR(./keepalive/@) $VAR(./holdtime/@)\"; \ fi; " diff --git a/templates/protocols/node.def b/templates/protocols/node.def index 3324e5fd..cdc0b969 100644 --- a/templates/protocols/node.def +++ b/templates/protocols/node.def @@ -1 +1 @@ -help: "Routing protocol configuration" +help: Routing protocol configuration diff --git a/templates/protocols/ospf/area/node.def b/templates/protocols/ospf/area/node.def index 339fa9c5..7da8f765 100644 --- a/templates/protocols/ospf/area/node.def +++ b/templates/protocols/ospf/area/node.def @@ -1,4 +1,4 @@ tag: type: txt -help: "OSPF Area" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-ospf-area $(@)"; "Invalid OSFP area \"$(@)\" " +help: OSPF Area +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-ospf-area $VAR(@)"; "Invalid OSFP area \"$VAR(@)\" " diff --git a/templates/protocols/ospf/area/node.tag/area-type/node.def b/templates/protocols/ospf/area/node.tag/area-type/node.def index 19c4ff6e..d5cceedb 100644 --- a/templates/protocols/ospf/area/node.tag/area-type/node.def +++ b/templates/protocols/ospf/area/node.tag/area-type/node.def @@ -1 +1 @@ -help: "Area type" +help: Area type diff --git a/templates/protocols/ospf/area/node.tag/area-type/normal/node.def b/templates/protocols/ospf/area/node.tag/area-type/normal/node.def index 784d2b4a..a55cfe79 100644 --- a/templates/protocols/ospf/area/node.tag/area-type/normal/node.def +++ b/templates/protocols/ospf/area/node.tag/area-type/normal/node.def @@ -1,8 +1,8 @@ -help: "Normal OSPF area" -syntax: $(../stub/) == "" ; "Must delete stub area type first" -syntax: $(../nssa/) == "" ; "Must delete nssa area type first" -create: "if [ x$(../../@) != x0.0.0.0 ] && [ x$(../../@) != x0 ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) stub\" -c \"no area $(../../@) nssa\"; \ +help: Normal OSPF area +syntax:expression: $VAR(../stub/) == "" ; "Must delete stub area type first" +syntax:expression: $VAR(../nssa/) == "" ; "Must delete nssa area type first" +create:expression: "if [ x$VAR(../../@) != x0.0.0.0 ] && [ x$VAR(../../@) != x0 ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) stub\" -c \"no area $VAR(../../@) nssa\"; \ fi; " 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 f3851e46..6446515b 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,7 +1,7 @@ type: u32 -help: "Set the summary-default cost of nssa area" -syntax: $(@) >= 0 && $(@) <= 16777215; "Cost must be between 0-16777215" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) default-cost $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) default-cost $(@)\"; " +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(@)\"; " 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 1b149db4..9bbd739f 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,5 +1,5 @@ -help: "Do not inject inter-area routes into stub" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) nssa no-summary \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) nssa no-summary \"; " +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 75cb20a8..6501dc8c 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 @@ -1,8 +1,8 @@ -help: "nssa OSPF area" -syntax: ! $(../../@) in "0", "0.0.0.0"; "Backbone can't be NSSA" -syntax: $(../normal/) == "" ; "Must delete normal area type first" -syntax: $(../stub/) == "" ; "Must delete stub area type first" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"area $(../../@) nssa\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"no area $(../../@) nssa\"; " +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\"; " 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 8c4d9f81..86616a8f 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 @@ -1,7 +1,7 @@ type: txt default: "candidate" -syntax: $(@) in "always", "candidate", "never"; "Must be (always, candidate, or never)" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) nssa translate-$(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) nssa translate-$(@) \"; " +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 \"no area $VAR(../../../@) nssa translate-$VAR(@) \"; " 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 6d82250d..bd29d813 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,7 +1,7 @@ type: u32 -help: "Set the summary-default cost of stub area" -syntax: $(@) >= 0 && $(@) <= 16777215; "Cost must be between 0-16777215" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) default-cost $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) default-cost $(@)\"; " +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(@)\"; " 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 750e6311..30cc830f 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,5 +1,5 @@ -help: "Do not inject inter-area routes into stub" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) stub no-summary \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) stub no-summary \"; " +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(../../../@) stub no-summary \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -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 1e975ff3..e39f36bc 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,8 +1,8 @@ -help: "Stub OSPF area" -syntax: ! $(../../@) in "0", "0.0.0.0"; "Backbone can't be stub" -syntax: $(../nssa/) == "" ; "Must delete nssa area type first" -syntax: $(../normal/) == "" ; "Must delete normal area type first" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) stub\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) stub\"; " +help: 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_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) stub\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) stub\"; " diff --git a/templates/protocols/ospf/area/node.tag/authentication/node.def b/templates/protocols/ospf/area/node.tag/authentication/node.def index f30c1c9a..2581eee1 100644 --- a/templates/protocols/ospf/area/node.tag/authentication/node.def +++ b/templates/protocols/ospf/area/node.tag/authentication/node.def @@ -1,17 +1,17 @@ type: txt -help: "Configure OSPF area authentication type" -syntax: $(@) in "simple", "md5"; "Must be either simple or md5" -update: "if [ x$(@) == xsimple ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ +help: Configure OSPF area authentication type +syntax:expression: $VAR(@) in "simple", "md5"; "Must be either simple or md5" +update:expression: "if [ x$VAR(@) == xsimple ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ -c \"router ospf \" \ - -c \"no area $(../@) authentication \" \ - -c \"area $(../@) authentication \" ; \ + -c \"no area $VAR(../@) authentication \" \ + -c \"area $VAR(../@) authentication \" ; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ -c \"router ospf \" \ - -c \"no area $(../@) authentication \" \ - -c \"area $(../@) authentication message-digest\" ; \ + -c \"no area $VAR(../@) authentication \" \ + -c \"area $VAR(../@) authentication message-digest\" ; \ fi; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" \ -c \"router ospf \" \ - -c \"no area $(../@) authentication \" " + -c \"no area $VAR(../@) authentication \" " diff --git a/templates/protocols/ospf/area/node.tag/network/node.def b/templates/protocols/ospf/area/node.tag/network/node.def index 9d345218..36aecb09 100644 --- a/templates/protocols/ospf/area/node.tag/network/node.def +++ b/templates/protocols/ospf/area/node.tag/network/node.def @@ -1,8 +1,8 @@ multi: type: ipv4net -help: "OSPF network" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"network $(@) area $(../@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no network $(@) area $(../@)\"; " +help: OSPF network +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"network $VAR(@) area $VAR(../@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no network $VAR(@) area $VAR(../@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/node.def b/templates/protocols/ospf/area/node.tag/node.def index 391ddf6b..2652108b 100644 --- a/templates/protocols/ospf/area/node.tag/node.def +++ b/templates/protocols/ospf/area/node.tag/node.def @@ -1,3 +1,3 @@ -help: "IPv4 network" +help: IPv4 network diff --git a/templates/protocols/ospf/area/node.tag/range/node.def b/templates/protocols/ospf/area/node.tag/range/node.def index b2b998e9..92d5512a 100644 --- a/templates/protocols/ospf/area/node.tag/range/node.def +++ b/templates/protocols/ospf/area/node.tag/range/node.def @@ -1,8 +1,8 @@ tag: type: ipv4net -help: "Summarize routes matching prefix (border routers only)" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../@) range $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../@) range $(@)\"; " +help: Summarize routes matching prefix (border routers only) +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../@) range $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../@) range $VAR(@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/range/node.tag/cost/node.def b/templates/protocols/ospf/area/node.tag/range/node.tag/cost/node.def index 46478b26..8716bd4b 100644 --- a/templates/protocols/ospf/area/node.tag/range/node.tag/cost/node.def +++ b/templates/protocols/ospf/area/node.tag/range/node.tag/cost/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Metric for this range" -syntax: $(@) >= 0 && $(@) <= 16777215; "Metric must be between 0-16777215" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) range $(../@) cost $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) range $(../@) cost $(@)\"; " +help: Metric for this range +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 16777215; "Metric must be between 0-16777215" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) range $VAR(../@) cost $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) range $VAR(../@) cost $VAR(@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/range/node.tag/node.def b/templates/protocols/ospf/area/node.tag/range/node.tag/node.def index 1a011c8c..f4440010 100644 --- a/templates/protocols/ospf/area/node.tag/range/node.tag/node.def +++ b/templates/protocols/ospf/area/node.tag/range/node.tag/node.def @@ -1 +1 @@ -help: "what should I put here" +help: what should I put here diff --git a/templates/protocols/ospf/area/node.tag/range/node.tag/not-advertise/node.def b/templates/protocols/ospf/area/node.tag/range/node.tag/not-advertise/node.def index cf56efe4..748e264d 100644 --- a/templates/protocols/ospf/area/node.tag/range/node.tag/not-advertise/node.def +++ b/templates/protocols/ospf/area/node.tag/range/node.tag/not-advertise/node.def @@ -1,5 +1,5 @@ -help: "Do NOT advertise this range" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) range $(../@) not-advertise\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) range $(../@) not-advertise\"; " +help: Do NOT advertise this range +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) range $VAR(../@) not-advertise\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) range $VAR(../@) not-advertise\"; " diff --git a/templates/protocols/ospf/area/node.tag/range/node.tag/substitute/node.def b/templates/protocols/ospf/area/node.tag/range/node.tag/substitute/node.def index 9b1243b4..d4276cfc 100644 --- a/templates/protocols/ospf/area/node.tag/range/node.tag/substitute/node.def +++ b/templates/protocols/ospf/area/node.tag/range/node.tag/substitute/node.def @@ -1,7 +1,7 @@ type: ipv4net -help: "Announce area range as another prefix" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) range $(../@) substitute $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) range $(../@) substitute $(@)\"; " +help: Announce area range as another prefix +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) range $VAR(../@) substitute $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) range $VAR(../@) substitute $VAR(@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/shortcut/node.def b/templates/protocols/ospf/area/node.tag/shortcut/node.def index 975d8563..b41d7195 100644 --- a/templates/protocols/ospf/area/node.tag/shortcut/node.def +++ b/templates/protocols/ospf/area/node.tag/shortcut/node.def @@ -1,7 +1,7 @@ type: txt -help: "Configure area's shortcutting mode" -syntax: $(@) in "default", "disable", "enable"; "Must be (default, disable, enable)" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../@) shortcut $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../@) shortcut $(@)\"; " +help: Configure area's shortcutting mode +syntax:expression: $VAR(@) in "default", "disable", "enable"; "Must be (default, disable, enable)" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../@) shortcut $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../@) shortcut $VAR(@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.def index 8f305002..ba21aa64 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.def @@ -1,8 +1,8 @@ tag: type: ipv4 -help: "Configure a virtual link" -syntax: ! $(../@) in "0", "0.0.0.0"; "Can't configure VL over area $(../@)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../@) virtual-link $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../@) virtual-link $(@)\"; " +help: Configure a virtual link +syntax:expression: ! $VAR(../@) in "0", "0.0.0.0"; "Can't configure VL over area $VAR(../@)" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../@) virtual-link $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../@) virtual-link $VAR(@)\"; " diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.def index 5bb35317..eff0d6be 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.def @@ -1,16 +1,16 @@ tag: type: u32 -help: "Configure MD5 key id" -syntax: $(@) >= 1 && $(@) <= 255; "ID must be between (1-255)" -commit: $(md5-key/) != ""; "must add the md5-key for key-id $(@)" -delete: "touch /tmp/ospf-md5.\\$PPID" -end: "if [ -f \"/tmp/ospf-md5.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../../@) virtual-link $(../../../@) message-digest-key $(@)\"; \ - rm /tmp/ospf-md5.\\$PPID; \ +help: Configure MD5 key id +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "ID must be between (1-255)" +commit:expression: $VAR(md5-key/) != ""; "must add the md5-key for key-id $VAR(@)" +delete:expression: "touch /tmp/ospf-md5.$PPID" +end:expression: "if [ -f \"/tmp/ospf-md5.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../../../@) virtual-link $VAR(../../../@) message-digest-key $VAR(@)\"; \ + rm /tmp/ospf-md5.$PPID; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../../@) virtual-link $(../../../@) message-digest-key $(@) md5 $(md5-key/@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../../../@) virtual-link $VAR(../../../@) message-digest-key $VAR(@) md5 $VAR(md5-key/@)\"; \ fi; " diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/md5-key/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/md5-key/node.def index 54bbd8f7..3efdfdd3 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/md5-key/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/md5-key/node.def @@ -1,2 +1,2 @@ type: txt -help: "Configure md5 key" +help: Configure md5 key diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/node.def index 7d644d6f..c90f5cf9 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/key-id/node.tag/node.def @@ -1 +1 @@ -help: "Configure md5 key" +help: Configure md5 key diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/node.def index aaf79ced..7fd09ba1 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/md5/node.def @@ -1,6 +1,6 @@ -help: "Configure MD5 key id" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) virtual-link $(../../@) authentication-key\" \ - -c \"area $(../../../@) virtual-link $(../../@) authentication message-digest\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) virtual-link $(../../@) authentication null\"; " +help: Configure MD5 key id +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../../@) virtual-link $VAR(../../@) authentication-key\" \ + -c \"area $VAR(../../../@) virtual-link $VAR(../../@) authentication message-digest\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../../@) virtual-link $VAR(../../@) authentication null\"; " diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/node.def index ba787ac5..0e0aad62 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/node.def @@ -1 +1 @@ -help: "Configure authentication" +help: Configure authentication diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/simple/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/simple/node.def index 253572a3..36a924d2 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/simple/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/authentication/simple/node.def @@ -1,7 +1,7 @@ type: txt -help: "Configure simple password" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../../@) virtual-link $(../../@) authentication authentication-key $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../../@) virtual-link $(../../@) authentication authentication-key \"; " +help: Configure simple password +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../../@) virtual-link $VAR(../../@) authentication authentication-key $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../../@) virtual-link $VAR(../../@) authentication authentication-key \"; " diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/dead-interval/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/dead-interval/node.def index 7e66e018..179800a2 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/dead-interval/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/dead-interval/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Interval after which a neighbor is declared dead" -syntax: $(@) >= 1 && $(@) <= 65535; "Must be between 1-65535" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) virtual-link $(../@) dead-interval $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) virtual-link $(../@) dead-interval \"; " -#comp_help: <1-65535> Seconds +help: Interval after which a neighbor is declared dead +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Must be between 1-65535" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) virtual-link $VAR(../@) dead-interval $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) virtual-link $VAR(../@) dead-interval \"; " +comp_help: <1-65535> Seconds diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/hello-interval/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/hello-interval/node.def index dc63aad8..29ee19e0 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/hello-interval/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/hello-interval/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Interval between HELLO packets" -syntax: $(@) >= 1 && $(@) <= 65535; "Must be between 1-65535" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) virtual-link $(../@) hello-interval $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) virtual-link $(../@) hello-interval \"; " -#comp_help: <1-65535> Seconds +help: Interval between HELLO packets +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Must be between 1-65535" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) virtual-link $VAR(../@) hello-interval $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) virtual-link $VAR(../@) hello-interval \"; " +comp_help: <1-65535> Seconds diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/node.def index 5dbaf4af..dd576aa7 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/node.def @@ -1 +1 @@ -help: "virtual link" +help: virtual link diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/retransmit-interval/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/retransmit-interval/node.def index 2edda12f..5e227a08 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/retransmit-interval/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/retransmit-interval/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Interval between retransmitting lost link state advertisements" -syntax: $(@) >= 1 && $(@) <= 65535; "Must be between 1-65535" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) virtual-link $(../@) retransmit-interval $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) virtual-link $(../@) retransmit-interval \"; " -#comp_help: <1-65535> Seconds +help: Interval between retransmitting lost link state advertisements +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Must be between 1-65535" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) virtual-link $VAR(../@) retransmit-interval $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) virtual-link $VAR(../@) retransmit-interval \"; " +comp_help: <1-65535> Seconds diff --git a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/transmit-delay/node.def b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/transmit-delay/node.def index 9dc9a8d2..c829dc4d 100644 --- a/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/transmit-delay/node.def +++ b/templates/protocols/ospf/area/node.tag/virtual-link/node.tag/transmit-delay/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Link state transmit delay" -syntax: $(@) >= 1 && $(@) <= 65535; "Must be between 1-65535" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"area $(../../@) virtual-link $(../@) transmit-delay $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no area $(../../@) virtual-link $(../@) transmit-delay \"; " -#comp_help: <1-65535> Seconds +help: Link state transmit delay +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Must be between 1-65535" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"area $VAR(../../@) virtual-link $VAR(../@) transmit-delay $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no area $VAR(../../@) virtual-link $VAR(../@) transmit-delay \"; " +comp_help: <1-65535> Seconds diff --git a/templates/protocols/ospf/auto-cost/node.def b/templates/protocols/ospf/auto-cost/node.def index 54a3e80c..5ea6ce6f 100644 --- a/templates/protocols/ospf/auto-cost/node.def +++ b/templates/protocols/ospf/auto-cost/node.def @@ -1 +1 @@ -help: "Calculate OSPF interface cost according to bandwidth" +help: Calculate OSPF interface cost according to bandwidth diff --git a/templates/protocols/ospf/auto-cost/reference-bandwidth/node.def b/templates/protocols/ospf/auto-cost/reference-bandwidth/node.def index b5a97e7b..3b87c973 100644 --- a/templates/protocols/ospf/auto-cost/reference-bandwidth/node.def +++ b/templates/protocols/ospf/auto-cost/reference-bandwidth/node.def @@ -1,5 +1,5 @@ type: u32 -help: "Use reference bandwidth method to assign OSPF cost in Mbits/sec" -syntax: $(@) >= 1 && $(@) <= 4294967; "Must be between 1-4294967" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"auto-cost reference-bandwidth $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"no auto-cost reference-bandwidth \"; " +help: Use reference bandwidth method to assign OSPF cost in Mbits/sec +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 4294967; "Must be between 1-4294967" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"auto-cost reference-bandwidth $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"no auto-cost reference-bandwidth \"; " diff --git a/templates/protocols/ospf/capability/node.def b/templates/protocols/ospf/capability/node.def index 18402df4..089d322e 100644 --- a/templates/protocols/ospf/capability/node.def +++ b/templates/protocols/ospf/capability/node.def @@ -1 +1 @@ -help: "Enable specific OSPF feature" +help: Enable specific OSPF feature diff --git a/templates/protocols/ospf/capability/opaque/node.def b/templates/protocols/ospf/capability/opaque/node.def index 5dfed2af..d4ffb775 100644 --- a/templates/protocols/ospf/capability/opaque/node.def +++ b/templates/protocols/ospf/capability/opaque/node.def @@ -1,3 +1,3 @@ -help: "Opaque LSA" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"capability opaque\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"no capability opaque\"; " +help: Opaque LSA +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"capability opaque\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" -c \"no capability opaque\"; " diff --git a/templates/protocols/ospf/compatible/node.def b/templates/protocols/ospf/compatible/node.def index d398cf75..a92c9f0e 100644 --- a/templates/protocols/ospf/compatible/node.def +++ b/templates/protocols/ospf/compatible/node.def @@ -1 +1 @@ -help: "OSPF compatibility list" +help: OSPF compatibility list diff --git a/templates/protocols/ospf/compatible/rfc1583/node.def b/templates/protocols/ospf/compatible/rfc1583/node.def index e896c274..1d12f741 100644 --- a/templates/protocols/ospf/compatible/rfc1583/node.def +++ b/templates/protocols/ospf/compatible/rfc1583/node.def @@ -1,5 +1,5 @@ -help: "compatible with RFC 1583" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: compatible with RFC 1583 +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"compatible rfc1583\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no compatible rfc1583\"; " diff --git a/templates/protocols/ospf/default-information/node.def b/templates/protocols/ospf/default-information/node.def index f50bef38..7cd4ddbc 100644 --- a/templates/protocols/ospf/default-information/node.def +++ b/templates/protocols/ospf/default-information/node.def @@ -1 +1 @@ -help: "Control distribution of default information" +help: Control distribution of default information diff --git a/templates/protocols/ospf/default-information/originate/always/node.def b/templates/protocols/ospf/default-information/originate/always/node.def index e2a93034..31ce00db 100644 --- a/templates/protocols/ospf/default-information/originate/always/node.def +++ b/templates/protocols/ospf/default-information/originate/always/node.def @@ -1 +1 @@ -help: "Always advertise default route" +help: Always advertise default route diff --git a/templates/protocols/ospf/default-information/originate/metric-type/node.def b/templates/protocols/ospf/default-information/originate/metric-type/node.def index 6e7f91b5..81ed06c4 100644 --- a/templates/protocols/ospf/default-information/originate/metric-type/node.def +++ b/templates/protocols/ospf/default-information/originate/metric-type/node.def @@ -1,4 +1,4 @@ type: txt -help: "OSPF metric type for default routes" +help: OSPF metric type for default routes default: "2" -syntax: $(@) in "1", "2"; "Must be either 1 or 2" +syntax:expression: $VAR(@) in "1", "2"; "Must be either 1 or 2" diff --git a/templates/protocols/ospf/default-information/originate/metric/node.def b/templates/protocols/ospf/default-information/originate/metric/node.def index bef11e38..cd51e49f 100644 --- a/templates/protocols/ospf/default-information/originate/metric/node.def +++ b/templates/protocols/ospf/default-information/originate/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "OSPF default metric" -syntax: $(@) >= 0 && $(@) <= 16777214; "must be between 0-16777214" +help: OSPF default metric +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 16777214; "must be between 0-16777214" diff --git a/templates/protocols/ospf/default-information/originate/node.def b/templates/protocols/ospf/default-information/originate/node.def index 5772bdcb..d0ecb7b2 100644 --- a/templates/protocols/ospf/default-information/originate/node.def +++ b/templates/protocols/ospf/default-information/originate/node.def @@ -1,21 +1,21 @@ -help: "Distribute a default route" -delete: "touch /tmp/ospf-default-info.\\$PPID" -end: "if [ -f \"/tmp/ospf-default-info.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Distribute a default route +delete:expression: "touch /tmp/ospf-default-info.$PPID" +end:expression: "if [ -f \"/tmp/ospf-default-info.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no default-information originate \"; \ else \ - if [ -n \"$(./always/@)\" ]; then \ - PARM=\"always\"; \ + if [ -n \"$VAR(./always/@)\" ]; then \ + PARM=\"always\"; \ fi; \ - if [ -n \"$(./metric/@)\" ]; then \ - PARM=\"\\$PARM metric $(./metric/@)\"; \ + if [ -n \"$VAR(./metric/@)\" ]; then \ + PARM=\"$PARM metric $VAR(./metric/@)\"; \ fi; \ - if [ -n \"$(./metric-type/@)\" ]; then \ - PARM=\"\\$PARM metric-type $(./metric-type/@)\"; \ + if [ -n \"$VAR(./metric-type/@)\" ]; then \ + PARM=\"$PARM metric-type $VAR(./metric-type/@)\"; \ fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - PARM=\"\\$PARM route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + PARM=\"$PARM route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"default-information originate \\$PARM\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"default-information originate $PARM\"; \ fi; " diff --git a/templates/protocols/ospf/default-information/originate/route-map/node.def b/templates/protocols/ospf/default-information/originate/route-map/node.def index 5b4f587e..c7943078 100644 --- a/templates/protocols/ospf/default-information/originate/route-map/node.def +++ b/templates/protocols/ospf/default-information/originate/route-map/node.def @@ -1,2 +1,2 @@ type: txt -help: "Route map reference" +help: Route map reference diff --git a/templates/protocols/ospf/default-metric/node.def b/templates/protocols/ospf/default-metric/node.def index f147d611..8549f529 100644 --- a/templates/protocols/ospf/default-metric/node.def +++ b/templates/protocols/ospf/default-metric/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Set metric of redistributed routes" -syntax: $(@) >= 0 && $(@) <= 16777214; "Must be between 0-16777214" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"default-metric $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no default-metric $(@) \"; " +help: Set metric of redistributed routes +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 16777214; "Must be between 0-16777214" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"default-metric $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no default-metric $VAR(@) \"; " diff --git a/templates/protocols/ospf/distance/global/node.def b/templates/protocols/ospf/distance/global/node.def index d88a761b..3a86f3de 100644 --- a/templates/protocols/ospf/distance/global/node.def +++ b/templates/protocols/ospf/distance/global/node.def @@ -1,9 +1,9 @@ type: u32 -help: "OSPF administrative distance" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between 1-255" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"distance $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no distance $(@) \"; " +help: OSPF administrative distance +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between 1-255" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"distance $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no distance $VAR(@) \"; " diff --git a/templates/protocols/ospf/distance/node.def b/templates/protocols/ospf/distance/node.def index fdc52f32..f86a74d1 100644 --- a/templates/protocols/ospf/distance/node.def +++ b/templates/protocols/ospf/distance/node.def @@ -1 +1 @@ -help: "Define an administrative distance" +help: Define an administrative distance diff --git a/templates/protocols/ospf/distance/ospf/external/node.def b/templates/protocols/ospf/distance/ospf/external/node.def index 696e14b7..19f3be51 100644 --- a/templates/protocols/ospf/distance/ospf/external/node.def +++ b/templates/protocols/ospf/distance/ospf/external/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Define a distance for external routes" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between 1-255" +help: Define a distance for external routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between 1-255" diff --git a/templates/protocols/ospf/distance/ospf/inter-area/node.def b/templates/protocols/ospf/distance/ospf/inter-area/node.def index 1e2fa5ba..54902c54 100644 --- a/templates/protocols/ospf/distance/ospf/inter-area/node.def +++ b/templates/protocols/ospf/distance/ospf/inter-area/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Define a distance for inter-area routes" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between 1-255" +help: Define a distance for inter-area routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between 1-255" diff --git a/templates/protocols/ospf/distance/ospf/intra-area/node.def b/templates/protocols/ospf/distance/ospf/intra-area/node.def index cae2bf0f..e4f4b5c2 100644 --- a/templates/protocols/ospf/distance/ospf/intra-area/node.def +++ b/templates/protocols/ospf/distance/ospf/intra-area/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Define a distance for intra-area routes" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between 1-255" +help: Define a distance for intra-area routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between 1-255" diff --git a/templates/protocols/ospf/distance/ospf/node.def b/templates/protocols/ospf/distance/ospf/node.def index fa49eaa1..f003de8a 100644 --- a/templates/protocols/ospf/distance/ospf/node.def +++ b/templates/protocols/ospf/distance/ospf/node.def @@ -1,19 +1,19 @@ -help: "OSPF administrative distance" -delete: "touch /tmp/ospf-distance.\\$PPID" -end: "if [ -f \"/tmp/ospf-distance.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: OSPF administrative distance +delete:expression: "touch /tmp/ospf-distance.$PPID" +end:expression: "if [ -f \"/tmp/ospf-distance.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no distance ospf\"; \ - rm /tmp/ospf-distance.\\$PPID; \ + rm /tmp/ospf-distance.$PPID; \ else \ - if [ -n \"$(./intra-area/@)\" ]; then \ - PARM=\"intra-area $(./intra-area/@)\"; \ + if [ -n \"$VAR(./intra-area/@)\" ]; then \ + PARM=\"intra-area $VAR(./intra-area/@)\"; \ fi; \ - if [ -n \"$(./inter-area/@)\" ]; then \ - PARM=\"\\$PARM inter-area $(./inter-area/@)\"; \ + if [ -n \"$VAR(./inter-area/@)\" ]; then \ + PARM=\"$PARM inter-area $VAR(./inter-area/@)\"; \ fi; \ - if [ -n \"$(./external/@)\" ]; then \ - PARM=\"\\$PARM external $(./external/@)\"; \ + if [ -n \"$VAR(./external/@)\" ]; then \ + PARM=\"$PARM external $VAR(./external/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no distance ospf\" -c \"distance ospf \\$PARM\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no distance ospf\" -c \"distance ospf $PARM\"; \ fi; " diff --git a/templates/protocols/ospf/distribute-list/node.def b/templates/protocols/ospf/distribute-list/node.def index bd170cd6..9f4a8f06 100644 --- a/templates/protocols/ospf/distribute-list/node.def +++ b/templates/protocols/ospf/distribute-list/node.def @@ -1,4 +1,4 @@ tag: type: txt -commit: $(./out/) != ""; "must add protocol to filter" -help: "access-list to filter networks in routing updates" +commit:expression: $VAR(./out/) != ""; "must add protocol to filter" +help: access-list to filter networks in routing updates diff --git a/templates/protocols/ospf/distribute-list/node.tag/out/node.def b/templates/protocols/ospf/distribute-list/node.tag/out/node.def index cd2f1200..819ff774 100644 --- a/templates/protocols/ospf/distribute-list/node.tag/out/node.def +++ b/templates/protocols/ospf/distribute-list/node.tag/out/node.def @@ -1,8 +1,8 @@ multi: type: txt -help: "Filter outgoing routing updates" -syntax: $(@) in "bgp", "connected", "isis", "kernel", "rip", "static"; "Must be (bgp, connected, isis, kernel, rip, or static" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"distribute-list $(../@) out $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no distribute-list $(../@) out $(@) \"; " +help: Filter outgoing routing updates +syntax:expression: $VAR(@) in "bgp", "connected", "isis", "kernel", "rip", "static"; "Must be (bgp, connected, isis, kernel, rip, or static" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"distribute-list $VAR(../@) out $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no distribute-list $VAR(../@) out $VAR(@) \"; " diff --git a/templates/protocols/ospf/log-adjacency-changes/detail/node.def b/templates/protocols/ospf/log-adjacency-changes/detail/node.def index cffc4455..89c2bb75 100644 --- a/templates/protocols/ospf/log-adjacency-changes/detail/node.def +++ b/templates/protocols/ospf/log-adjacency-changes/detail/node.def @@ -1,6 +1,6 @@ -help: "Log all state changes" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Log all state changes +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"log-adjacency-changes detail\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no log-adjacency-changes detail\"; " diff --git a/templates/protocols/ospf/log-adjacency-changes/node.def b/templates/protocols/ospf/log-adjacency-changes/node.def index 0c07be4a..9897c04e 100644 --- a/templates/protocols/ospf/log-adjacency-changes/node.def +++ b/templates/protocols/ospf/log-adjacency-changes/node.def @@ -1,5 +1,5 @@ -help: "Log changes in adjacency state" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Log changes in adjacency state +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"log-adjacency-changes\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no log-adjacency-changes\"; " diff --git a/templates/protocols/ospf/max-metric/node.def b/templates/protocols/ospf/max-metric/node.def index 1295623c..812172f8 100644 --- a/templates/protocols/ospf/max-metric/node.def +++ b/templates/protocols/ospf/max-metric/node.def @@ -1 +1 @@ -help: "OSPF maximum / infinite-distance metric" +help: OSPF maximum / infinite-distance metric diff --git a/templates/protocols/ospf/max-metric/router-lsa/administrative/node.def b/templates/protocols/ospf/max-metric/router-lsa/administrative/node.def index 0f7c2ba6..1ad32f4c 100644 --- a/templates/protocols/ospf/max-metric/router-lsa/administrative/node.def +++ b/templates/protocols/ospf/max-metric/router-lsa/administrative/node.def @@ -1,7 +1,7 @@ -help: "Administratively applied, for an indefinite period" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Administratively applied, for an indefinite period +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"max-metric router-lsa administrative\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no max-metric router-lsa administrative \"; " diff --git a/templates/protocols/ospf/max-metric/router-lsa/node.def b/templates/protocols/ospf/max-metric/router-lsa/node.def index 61c4d253..7371f9a9 100644 --- a/templates/protocols/ospf/max-metric/router-lsa/node.def +++ b/templates/protocols/ospf/max-metric/router-lsa/node.def @@ -1 +1 @@ -help: "Advertise own Router-LSA with infinite distance (stub router)" +help: Advertise own Router-LSA with infinite distance (stub router) diff --git a/templates/protocols/ospf/max-metric/router-lsa/on-shutdown/node.def b/templates/protocols/ospf/max-metric/router-lsa/on-shutdown/node.def index 55a08828..d69a33dc 100644 --- a/templates/protocols/ospf/max-metric/router-lsa/on-shutdown/node.def +++ b/templates/protocols/ospf/max-metric/router-lsa/on-shutdown/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Advertise stub-router prior to full shutdown of OSPF" -syntax: $(@) >= 5 && $(@) <= 86400; "must be between 5-86400 seconds" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"max-metric router-lsa on-shutdown $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Advertise stub-router prior to full shutdown of OSPF +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 86400; "must be between 5-86400 seconds" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"max-metric router-lsa on-shutdown $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no max-metric router-lsa on-shutdown \"; " -#comp_help: Time (seconds) to advertise self as stub-router" +comp_help: Time (seconds) to advertise self as stub-router" diff --git a/templates/protocols/ospf/max-metric/router-lsa/on-startup/node.def b/templates/protocols/ospf/max-metric/router-lsa/on-startup/node.def index f9c9432d..492f7334 100644 --- a/templates/protocols/ospf/max-metric/router-lsa/on-startup/node.def +++ b/templates/protocols/ospf/max-metric/router-lsa/on-startup/node.def @@ -1,9 +1,9 @@ type: u32 -help: "Automatically advertise stub Router-LSA on startup of OSPF" -syntax: $(@) >= 5 && $(@) <= 86400; "must be between 5-86400 seconds" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"max-metric router-lsa on-startup $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Automatically advertise stub Router-LSA on startup of OSPF +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 86400; "must be between 5-86400 seconds" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"max-metric router-lsa on-startup $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no max-metric router-lsa on-startup \"; " -#comp_help: Time (seconds) to advertise self as stub-router" +comp_help: Time (seconds) to advertise self as stub-router" diff --git a/templates/protocols/ospf/mpls-te/enable/node.def b/templates/protocols/ospf/mpls-te/enable/node.def index 22804817..c502bee8 100644 --- a/templates/protocols/ospf/mpls-te/enable/node.def +++ b/templates/protocols/ospf/mpls-te/enable/node.def @@ -1,5 +1,5 @@ -help: "Enable the MPLS-TE functionality" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Enable the MPLS-TE functionality +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"mpls-te on\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no mpls-te\"; " diff --git a/templates/protocols/ospf/mpls-te/node.def b/templates/protocols/ospf/mpls-te/node.def index 997d3406..691c56d6 100644 --- a/templates/protocols/ospf/mpls-te/node.def +++ b/templates/protocols/ospf/mpls-te/node.def @@ -1 +1 @@ -help: "Configure MPLS-TE parameters" +help: Configure MPLS-TE parameters diff --git a/templates/protocols/ospf/mpls-te/router-address/node.def b/templates/protocols/ospf/mpls-te/router-address/node.def index 6a0fdfee..b2ee1b8b 100644 --- a/templates/protocols/ospf/mpls-te/router-address/node.def +++ b/templates/protocols/ospf/mpls-te/router-address/node.def @@ -1,6 +1,6 @@ type: ipv4 -help: "Stable IP address of the advertising router" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"mpls-te router-address $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Stable IP address of the advertising router +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"mpls-te router-address $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no mpls-te\"; " diff --git a/templates/protocols/ospf/neighbor/node.def b/templates/protocols/ospf/neighbor/node.def index baa994d8..c07df296 100644 --- a/templates/protocols/ospf/neighbor/node.def +++ b/templates/protocols/ospf/neighbor/node.def @@ -1,7 +1,7 @@ tag: type: ipv4 -help: "Neighbor IP address" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"neighbor $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no neighbor $(@)\"; " +help: Neighbor IP address +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"neighbor $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no neighbor $VAR(@)\"; " diff --git a/templates/protocols/ospf/neighbor/node.tag/poll-interval/node.def b/templates/protocols/ospf/neighbor/node.tag/poll-interval/node.def index 9bd63ae0..25cd1662 100644 --- a/templates/protocols/ospf/neighbor/node.tag/poll-interval/node.def +++ b/templates/protocols/ospf/neighbor/node.tag/poll-interval/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Dead neighbor polling interval" -syntax: $(@) >= 1 && $(@) <= 65535; "Must be between 1-65535 seconds" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"neighbor $(../@) poll-interval $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no neighbor $(../@) poll-interval $(@)\"; " +help: Dead neighbor polling interval +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 65535; "Must be between 1-65535 seconds" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"neighbor $VAR(../@) poll-interval $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no neighbor $VAR(../@) poll-interval $VAR(@)\"; " diff --git a/templates/protocols/ospf/neighbor/node.tag/priority/node.def b/templates/protocols/ospf/neighbor/node.tag/priority/node.def index 7d50ed8b..3f5730de 100644 --- a/templates/protocols/ospf/neighbor/node.tag/priority/node.def +++ b/templates/protocols/ospf/neighbor/node.tag/priority/node.def @@ -1,7 +1,7 @@ type: u32 -help: "Neighbor priority in seconds" -syntax: $(@) >= 0 && $(@) <= 255; "Priority must be between 0-255" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"neighbor $(../@) priority $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no neighbor $(../@) priority $(@)\"; " +help: Neighbor priority in seconds +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 255; "Priority must be between 0-255" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"neighbor $VAR(../@) priority $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no neighbor $VAR(../@) priority $VAR(@)\"; " diff --git a/templates/protocols/ospf/node.def b/templates/protocols/ospf/node.def index 24cb31e8..e652deaa 100644 --- a/templates/protocols/ospf/node.def +++ b/templates/protocols/ospf/node.def @@ -1,3 +1,3 @@ -help: "Configure OSPF for IPv4" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router ospf\" " +help: Configure OSPF for IPv4 +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router ospf\" " diff --git a/templates/protocols/ospf/parameters/abr-type/node.def b/templates/protocols/ospf/parameters/abr-type/node.def index 9bd50e8a..f61fbbc9 100644 --- a/templates/protocols/ospf/parameters/abr-type/node.def +++ b/templates/protocols/ospf/parameters/abr-type/node.def @@ -1,8 +1,8 @@ type: txt -help: "Set OSPF ABR type" +help: Set OSPF ABR type default: "cisco" -syntax: $(@) in "cisco", "ibm", "shortcut", "standard"; "Must be (cisco, ibm, shortcut, standard)" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"ospf abr-type $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no ospf abr-type $(@)\"; " +syntax:expression: $VAR(@) in "cisco", "ibm", "shortcut", "standard"; "Must be (cisco, ibm, shortcut, standard)" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"ospf abr-type $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no ospf abr-type $VAR(@)\"; " diff --git a/templates/protocols/ospf/parameters/node.def b/templates/protocols/ospf/parameters/node.def index 95934f6e..050f78ae 100644 --- a/templates/protocols/ospf/parameters/node.def +++ b/templates/protocols/ospf/parameters/node.def @@ -1 +1 @@ -help: "OSPF specific commands" +help: OSPF specific commands diff --git a/templates/protocols/ospf/parameters/opaque-lsa/node.def b/templates/protocols/ospf/parameters/opaque-lsa/node.def index 9e1e5b14..194a8499 100644 --- a/templates/protocols/ospf/parameters/opaque-lsa/node.def +++ b/templates/protocols/ospf/parameters/opaque-lsa/node.def @@ -1,6 +1,6 @@ -help: "Enable the Opaque-LSA capability (rfc2370)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Enable the Opaque-LSA capability (rfc2370) +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"ospf opaque-lsa \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no ospf opaque-lsa \"; " diff --git a/templates/protocols/ospf/parameters/rfc1583-compatibility/node.def b/templates/protocols/ospf/parameters/rfc1583-compatibility/node.def index f689edb9..29b95c40 100644 --- a/templates/protocols/ospf/parameters/rfc1583-compatibility/node.def +++ b/templates/protocols/ospf/parameters/rfc1583-compatibility/node.def @@ -1,5 +1,5 @@ -help: "Enable rfc1583 criteria for handling AS external routes" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Enable rfc1583 criteria for handling AS external routes +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"ospf rfc1583compatibility \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no ospf rfc1583compatibility \"; " diff --git a/templates/protocols/ospf/parameters/router-id/node.def b/templates/protocols/ospf/parameters/router-id/node.def index b1902d49..77ceeaa3 100644 --- a/templates/protocols/ospf/parameters/router-id/node.def +++ b/templates/protocols/ospf/parameters/router-id/node.def @@ -1,6 +1,6 @@ type: ipv4 -help: "Override the default router identifier" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"ospf router-id $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Override the default router identifier +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"ospf router-id $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no ospf router-id \" " diff --git a/templates/protocols/ospf/passive-interface/node.def b/templates/protocols/ospf/passive-interface/node.def index f2b3267d..d0834c65 100644 --- a/templates/protocols/ospf/passive-interface/node.def +++ b/templates/protocols/ospf/passive-interface/node.def @@ -1,26 +1,26 @@ multi: type: txt -help: "Suppress routing updates on an interface" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ] && [ x$(@) != xdefault ]; then \ - echo ethernet interface $(@) doesn\\'t exist on this system ; \ +help: Suppress routing updates on an interface +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ] && [ x$VAR(@) != xdefault ]; then \ + echo ethernet interface $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -update: "if [ x$(x) == xdefault ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +update:expression: "if [ x$VAR(x) == xdefault ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"passive-interface default\"; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"passive-interface $(@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"passive-interface $VAR(@)\"; \ fi; " -delete: "if [ x$(x) == xdefault ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +delete:expression: "if [ x$VAR(x) == xdefault ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no passive-interface default\"; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no passive-interface $(@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no passive-interface $VAR(@)\"; \ fi; " -#allowed: local -a array; -# array=( /sys/class/net/{eth,vmnet}* ) ; -# echo -n ${array[@]##*/} +allowed: local -a array; + array=( /sys/class/net/{eth,vmnet}* ) ; + echo -n ${array[@]##*/} diff --git a/templates/protocols/ospf/redistribute/bgp/metric/node.def b/templates/protocols/ospf/redistribute/bgp/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/ospf/redistribute/bgp/metric/node.def +++ b/templates/protocols/ospf/redistribute/bgp/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/ospf/redistribute/bgp/node.def b/templates/protocols/ospf/redistribute/bgp/node.def index f09214b7..98856c8a 100644 --- a/templates/protocols/ospf/redistribute/bgp/node.def +++ b/templates/protocols/ospf/redistribute/bgp/node.def @@ -1,16 +1,16 @@ -help: "Redistribute BGP routes" -delete: "touch /tmp/ospf-redist-bgp.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Redistribute BGP routes +delete:expression: "touch /tmp/ospf-redist-bgp.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no redistribute bgp \"; \ - if [ -f \"/tmp/ospf-redist-bgp.\\$PPID\" ]; then \ - rm -rf /tmp/ospf-redist-bgp.\\$PPID; \ + if [ -f \"/tmp/ospf-redist-bgp.$PPID\" ]; then \ + rm -rf /tmp/ospf-redist-bgp.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"redistribute bgp \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"redistribute bgp $COND\"; \ fi; " diff --git a/templates/protocols/ospf/redistribute/bgp/route-map/node.def b/templates/protocols/ospf/redistribute/bgp/route-map/node.def index f6e81288..a56f5668 100644 --- a/templates/protocols/ospf/redistribute/bgp/route-map/node.def +++ b/templates/protocols/ospf/redistribute/bgp/route-map/node.def @@ -1,4 +1,4 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/ospf/redistribute/connected/metric/node.def b/templates/protocols/ospf/redistribute/connected/metric/node.def index d7ca3c34..8234167e 100644 --- a/templates/protocols/ospf/redistribute/connected/metric/node.def +++ b/templates/protocols/ospf/redistribute/connected/metric/node.def @@ -1,6 +1,6 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/ospf/redistribute/connected/node.def b/templates/protocols/ospf/redistribute/connected/node.def index 77d286dd..02fc58de 100644 --- a/templates/protocols/ospf/redistribute/connected/node.def +++ b/templates/protocols/ospf/redistribute/connected/node.def @@ -1,16 +1,16 @@ -help: "Redistribute connected routes" -delete: "touch /tmp/ospf-redist-connected.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Redistribute connected routes +delete:expression: "touch /tmp/ospf-redist-connected.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no redistribute connected \"; \ - if [ -f \"/tmp/ospf-redist-connected.\\$PPID\" ]; then \ - rm -rf /tmp/ospf-redist-connected.\\$PPID; \ + if [ -f \"/tmp/ospf-redist-connected.$PPID\" ]; then \ + rm -rf /tmp/ospf-redist-connected.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"redistribute connected \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"redistribute connected $COND\"; \ fi; " diff --git a/templates/protocols/ospf/redistribute/connected/route-map/node.def b/templates/protocols/ospf/redistribute/connected/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/ospf/redistribute/connected/route-map/node.def +++ b/templates/protocols/ospf/redistribute/connected/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/ospf/redistribute/kernel/metric/node.def b/templates/protocols/ospf/redistribute/kernel/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/ospf/redistribute/kernel/metric/node.def +++ b/templates/protocols/ospf/redistribute/kernel/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/ospf/redistribute/kernel/node.def b/templates/protocols/ospf/redistribute/kernel/node.def index f8ab05e6..d0fd8b97 100644 --- a/templates/protocols/ospf/redistribute/kernel/node.def +++ b/templates/protocols/ospf/redistribute/kernel/node.def @@ -1,16 +1,16 @@ -help: "Redistribute kernel routes" -delete: "touch /tmp/ospf-redist-kernel.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Redistribute kernel routes +delete:expression: "touch /tmp/ospf-redist-kernel.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no redistribute kernel \"; \ - if [ -f \"/tmp/ospf-redist-kernel.\\$PPID\" ]; then \ - rm -rf /tmp/ospf-redist-kernel.\\$PPID; \ + if [ -f \"/tmp/ospf-redist-kernel.$PPID\" ]; then \ + rm -rf /tmp/ospf-redist-kernel.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"redistribute kernel \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"redistribute kernel $COND\"; \ fi; " diff --git a/templates/protocols/ospf/redistribute/kernel/route-map/node.def b/templates/protocols/ospf/redistribute/kernel/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/ospf/redistribute/kernel/route-map/node.def +++ b/templates/protocols/ospf/redistribute/kernel/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/ospf/redistribute/node.def b/templates/protocols/ospf/redistribute/node.def index e46c9122..00eefa88 100644 --- a/templates/protocols/ospf/redistribute/node.def +++ b/templates/protocols/ospf/redistribute/node.def @@ -1 +1 @@ -help: "Redistribute information from another routing protocol" +help: Redistribute information from another routing protocol diff --git a/templates/protocols/ospf/redistribute/rip/metric/node.def b/templates/protocols/ospf/redistribute/rip/metric/node.def index 01a2dda7..80d13b5e 100644 --- a/templates/protocols/ospf/redistribute/rip/metric/node.def +++ b/templates/protocols/ospf/redistribute/rip/metric/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/ospf/redistribute/rip/node.def b/templates/protocols/ospf/redistribute/rip/node.def index fdf4ea4a..d78ad9e8 100644 --- a/templates/protocols/ospf/redistribute/rip/node.def +++ b/templates/protocols/ospf/redistribute/rip/node.def @@ -1,17 +1,17 @@ -help: "Redistribute RIP routes" -delete: "touch /tmp/ospf-redist-rip.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Redistribute RIP routes +delete:expression: "touch /tmp/ospf-redist-rip.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no redistribute rip \"; \ - if [ -f \"/tmp/ospf-redist-rip.\\$PPID\" ]; then \ - rm -rf /tmp/ospf-redist-rip.\\$PPID; \ + if [ -f \"/tmp/ospf-redist-rip.$PPID\" ]; then \ + rm -rf /tmp/ospf-redist-rip.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"redistribute rip \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"redistribute rip $COND\"; \ fi; " diff --git a/templates/protocols/ospf/redistribute/rip/route-map/node.def b/templates/protocols/ospf/redistribute/rip/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/ospf/redistribute/rip/route-map/node.def +++ b/templates/protocols/ospf/redistribute/rip/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/ospf/redistribute/static/metric/node.def b/templates/protocols/ospf/redistribute/static/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/ospf/redistribute/static/metric/node.def +++ b/templates/protocols/ospf/redistribute/static/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/ospf/redistribute/static/node.def b/templates/protocols/ospf/redistribute/static/node.def index ee9f387b..318c0fed 100644 --- a/templates/protocols/ospf/redistribute/static/node.def +++ b/templates/protocols/ospf/redistribute/static/node.def @@ -1,16 +1,16 @@ -help: "Redistribute static routes" -delete: "touch /tmp/ospf-redist-static.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: Redistribute static routes +delete:expression: "touch /tmp/ospf-redist-static.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no redistribute static \"; \ - if [ -f \"/tmp/ospf-redist-static.\\$PPID\" ]; then \ - rm -rf /tmp/ospf-redist-static.\\$PPID; \ + if [ -f \"/tmp/ospf-redist-static.$PPID\" ]; then \ + rm -rf /tmp/ospf-redist-static.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"redistribute static \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"redistribute static $COND\"; \ fi; " diff --git a/templates/protocols/ospf/redistribute/static/route-map/node.def b/templates/protocols/ospf/redistribute/static/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/ospf/redistribute/static/route-map/node.def +++ b/templates/protocols/ospf/redistribute/static/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/ospf/refresh/node.def b/templates/protocols/ospf/refresh/node.def index 0885963f..bfa1dca4 100644 --- a/templates/protocols/ospf/refresh/node.def +++ b/templates/protocols/ospf/refresh/node.def @@ -1 +1 @@ -help: "Adjust refresh parameters" +help: Adjust refresh parameters diff --git a/templates/protocols/ospf/refresh/timers/node.def b/templates/protocols/ospf/refresh/timers/node.def index fe181359..309ad572 100644 --- a/templates/protocols/ospf/refresh/timers/node.def +++ b/templates/protocols/ospf/refresh/timers/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Set refresh timer" -syntax: $(@) >= 10 && $(@) <= 1800; "must be between 10-1800" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no refresh timer\" -c \"refresh timer $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"no refresh timer $(@)\"; " -#comp_help: <10-1800> Timer value in seconds +help: Set refresh timer +syntax:expression: $VAR(@) >= 10 && $VAR(@) <= 1800; "must be between 10-1800" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no refresh timer\" -c \"refresh timer $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"no refresh timer $VAR(@)\"; " +comp_help: <10-1800> Timer value in seconds diff --git a/templates/protocols/ospf/timers/node.def b/templates/protocols/ospf/timers/node.def index d81f1b41..8c4873b2 100644 --- a/templates/protocols/ospf/timers/node.def +++ b/templates/protocols/ospf/timers/node.def @@ -1 +1 @@ -help: "Adjust routing timers" +help: Adjust routing timers diff --git a/templates/protocols/ospf/timers/throttle/node.def b/templates/protocols/ospf/timers/throttle/node.def index adac0fcb..0854aae8 100644 --- a/templates/protocols/ospf/timers/throttle/node.def +++ b/templates/protocols/ospf/timers/throttle/node.def @@ -1 +1 @@ -help: "Throttling adaptive timers" +help: Throttling adaptive timers diff --git a/templates/protocols/ospf/timers/throttle/spf/delay/node.def b/templates/protocols/ospf/timers/throttle/spf/delay/node.def index 28d24cee..cd7f8e1e 100644 --- a/templates/protocols/ospf/timers/throttle/spf/delay/node.def +++ b/templates/protocols/ospf/timers/throttle/spf/delay/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Delay (msec) from first change received till SPF calculation" +help: Delay (msec) from first change received till SPF calculation default: 200 -syntax: $(@) >= 0 && $(@) <= 600000; "must be between 0-600000" +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 600000; "must be between 0-600000" diff --git a/templates/protocols/ospf/timers/throttle/spf/initial-holdtime/node.def b/templates/protocols/ospf/timers/throttle/spf/initial-holdtime/node.def index a52b9b09..63ce7d98 100644 --- a/templates/protocols/ospf/timers/throttle/spf/initial-holdtime/node.def +++ b/templates/protocols/ospf/timers/throttle/spf/initial-holdtime/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Initial hold time(msec) between consecutive SPF calculations" +help: Initial hold time(msec) between consecutive SPF calculations default: 1000 -syntax: $(@) >= 0 && $(@) <= 600000; "must be between 0-600000" +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 600000; "must be between 0-600000" diff --git a/templates/protocols/ospf/timers/throttle/spf/max-holdtime/node.def b/templates/protocols/ospf/timers/throttle/spf/max-holdtime/node.def index fd5d6332..0577b425 100644 --- a/templates/protocols/ospf/timers/throttle/spf/max-holdtime/node.def +++ b/templates/protocols/ospf/timers/throttle/spf/max-holdtime/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Maximum hold time (msec)" +help: Maximum hold time (msec) default: 10000 -syntax: $(@) >= 0 && $(@) <= 600000; "must be between 0-600000" +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 600000; "must be between 0-600000" diff --git a/templates/protocols/ospf/timers/throttle/spf/node.def b/templates/protocols/ospf/timers/throttle/spf/node.def index 8478376a..86bb51b6 100644 --- a/templates/protocols/ospf/timers/throttle/spf/node.def +++ b/templates/protocols/ospf/timers/throttle/spf/node.def @@ -1,10 +1,10 @@ -help: "OSPF SPF timers" -delete: "touch /tmp/ospf-timer.\\$PPID" -end: "if [ -f \"/tmp/ospf-timer.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ +help: OSPF SPF timers +delete:expression: "touch /tmp/ospf-timer.$PPID" +end:expression: "if [ -f \"/tmp/ospf-timer.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ -c \"no timers throttle spf\"; \ - rm /tmp/ospf-timer.\\$PPID; \ + rm /tmp/ospf-timer.$PPID; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ - -c \"timers throttle spf $(delay/@) $(initial-holdtime/@) $(max-holdtime/@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router ospf\" \ + -c \"timers throttle spf $VAR(delay/@) $VAR(initial-holdtime/@) $VAR(max-holdtime/@)\"; \ fi; " diff --git a/templates/protocols/rip/default-distance/node.def b/templates/protocols/rip/default-distance/node.def index a8ff5914..5ad7b7b9 100644 --- a/templates/protocols/rip/default-distance/node.def +++ b/templates/protocols/rip/default-distance/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Administrative distance" -syntax: $(@) >= 1 && $(@) <= 255; "must be between 1 and 255" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distance $(@) \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distance $(@) \" " -#comp_help: Enter a distance valude between 1-255 +help: Administrative distance +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "must be between 1 and 255" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distance $VAR(@) \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distance $VAR(@) \" " +comp_help: Enter a distance valude between 1-255 diff --git a/templates/protocols/rip/default-information/node.def b/templates/protocols/rip/default-information/node.def index e7e295cd..7d35a646 100644 --- a/templates/protocols/rip/default-information/node.def +++ b/templates/protocols/rip/default-information/node.def @@ -1 +1 @@ -help: "Control distribution of default route" +help: Control distribution of default route diff --git a/templates/protocols/rip/default-information/originate/node.def b/templates/protocols/rip/default-information/originate/node.def index d5b7b20e..bfd93a81 100644 --- a/templates/protocols/rip/default-information/originate/node.def +++ b/templates/protocols/rip/default-information/originate/node.def @@ -1,6 +1,6 @@ -help: "Distribute a default route" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Distribute a default route +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"default-information originate\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no default-information originate\" " diff --git a/templates/protocols/rip/default-metric/node.def b/templates/protocols/rip/default-metric/node.def index 16ec94c0..81a2610a 100644 --- a/templates/protocols/rip/default-metric/node.def +++ b/templates/protocols/rip/default-metric/node.def @@ -1,8 +1,8 @@ type: u32 -help: "Set metric of redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "Must be between 1-16" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"default-metric $(@) \"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no default-metric $(@) \"; " +help: Set metric of redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "Must be between 1-16" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"default-metric $VAR(@) \"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no default-metric $VAR(@) \"; " #comp_help <1-16> Default metric diff --git a/templates/protocols/rip/distribute-list/access-list/in/node.def b/templates/protocols/rip/distribute-list/access-list/in/node.def index c78ad2fb..87eddf90 100644 --- a/templates/protocols/rip/distribute-list/access-list/in/node.def +++ b/templates/protocols/rip/distribute-list/access-list/in/node.def @@ -1,8 +1,8 @@ type: u32 -help: "access-list to apply to input packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list $(@) in\" " +help: access-list to apply to input packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list $VAR(@) in\" " diff --git a/templates/protocols/rip/distribute-list/access-list/node.def b/templates/protocols/rip/distribute-list/access-list/node.def index a76ae356..dd7917a7 100644 --- a/templates/protocols/rip/distribute-list/access-list/node.def +++ b/templates/protocols/rip/distribute-list/access-list/node.def @@ -1 +1 @@ -help: "Access-list" +help: Access-list diff --git a/templates/protocols/rip/distribute-list/access-list/out/node.def b/templates/protocols/rip/distribute-list/access-list/out/node.def index 96855ca4..4b7f6b85 100644 --- a/templates/protocols/rip/distribute-list/access-list/out/node.def +++ b/templates/protocols/rip/distribute-list/access-list/out/node.def @@ -1,8 +1,8 @@ type: u32 -help: "access-list to apply to output packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list $(@) out\" " +help: access-list to apply to output packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list $VAR(@) out\" " diff --git a/templates/protocols/rip/distribute-list/interface/node.def b/templates/protocols/rip/distribute-list/interface/node.def index ce00fdc9..70009e14 100644 --- a/templates/protocols/rip/distribute-list/interface/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.def @@ -1,10 +1,10 @@ tag: type: txt -help: "Apply filtering to an interface" -syntax: exec "if [ -z \"`ip addr | grep $(@) `\" ]; then \ - echo ethernet interface $(@) doesn\\'t exist on this system ; \ +help: Apply filtering to an interface +syntax:expression: exec "if [ -z \"`ip addr | grep $VAR(@) `\" ]; then \ + echo ethernet interface $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -#allowed: local -a array; -# array=( /sys/class/net/{eth,vmnet}* ) ; -# echo -n ${array[@]##*/} +allowed: local -a array; + array=( /sys/class/net/{eth,vmnet}* ) ; + echo -n ${array[@]##*/} diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/in/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/in/node.def index 4c0b0c1f..4b2bad82 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/in/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/in/node.def @@ -1,8 +1,8 @@ type: u32 -help: "access-list to apply to input packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list $(@) in $(../../@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list $(@) in $(../../@)\" " +help: access-list to apply to input packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list $VAR(@) in $VAR(../../@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list $VAR(@) in $VAR(../../@)\" " diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/node.def index a76ae356..dd7917a7 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/node.def @@ -1 +1 @@ -help: "Access-list" +help: Access-list diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/out/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/out/node.def index a3d4477c..5362c410 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/access-list/out/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/access-list/out/node.def @@ -1,7 +1,7 @@ type: u32 -help: "access-list to apply to output packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list $(@) out $(../../@) \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list $(@) out $(../../@) \" " +help: access-list to apply to output packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list $VAR(@) out $VAR(../../@) \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list $VAR(@) out $VAR(../../@) \" " diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/in/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/in/node.def index ce3de387..2c02beba 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/in/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/in/node.def @@ -1,7 +1,7 @@ type: txt -help: "prefix-list to apply to input packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list prefix $(@) in $(../../@) \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list prefix $(@) in $(../../@) \" " +help: prefix-list to apply to input packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list prefix $VAR(@) in $VAR(../../@) \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list prefix $VAR(@) in $VAR(../../@) \" " diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/node.def index f30db7e7..2aa289c3 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/node.def @@ -1 +1 @@ -help: "Prefix-list" +help: Prefix-list diff --git a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/out/node.def b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/out/node.def index 48a97014..bd441e02 100644 --- a/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/out/node.def +++ b/templates/protocols/rip/distribute-list/interface/node.tag/prefix-list/out/node.def @@ -1,7 +1,7 @@ type: txt -help: "prefix-list to apply to output packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list prefix $(@) out $(../../@) \" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list prefix $(@) out $(../../@)\" " +help: prefix-list to apply to output packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list prefix $VAR(@) out $VAR(../../@) \" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list prefix $VAR(@) out $VAR(../../@)\" " diff --git a/templates/protocols/rip/distribute-list/node.def b/templates/protocols/rip/distribute-list/node.def index 89d561fe..34c3cd35 100644 --- a/templates/protocols/rip/distribute-list/node.def +++ b/templates/protocols/rip/distribute-list/node.def @@ -1,2 +1,2 @@ -help: "Filter networks in routing updates" +help: Filter networks in routing updates diff --git a/templates/protocols/rip/distribute-list/prefix-list/in/node.def b/templates/protocols/rip/distribute-list/prefix-list/in/node.def index 2a79d94e..c4966d6f 100644 --- a/templates/protocols/rip/distribute-list/prefix-list/in/node.def +++ b/templates/protocols/rip/distribute-list/prefix-list/in/node.def @@ -1,8 +1,8 @@ type: txt -help: "prefix-list to apply to input packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list prefix $(@) in\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list prefix $(@) in\" " +help: prefix-list to apply to input packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list prefix $VAR(@) in\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list prefix $VAR(@) in\" " diff --git a/templates/protocols/rip/distribute-list/prefix-list/node.def b/templates/protocols/rip/distribute-list/prefix-list/node.def index f30db7e7..2aa289c3 100644 --- a/templates/protocols/rip/distribute-list/prefix-list/node.def +++ b/templates/protocols/rip/distribute-list/prefix-list/node.def @@ -1 +1 @@ -help: "Prefix-list" +help: Prefix-list diff --git a/templates/protocols/rip/distribute-list/prefix-list/out/node.def b/templates/protocols/rip/distribute-list/prefix-list/out/node.def index 78d3f8bd..b488ffdb 100644 --- a/templates/protocols/rip/distribute-list/prefix-list/out/node.def +++ b/templates/protocols/rip/distribute-list/prefix-list/out/node.def @@ -1,7 +1,7 @@ type: txt -help: "prefix-list to apply to output packets" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $(@)\" ";"prefix-list $(@) doesn't exist" -update: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distribute-list prefix $(@) out\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distribute-list prefix $(@) out\" " +help: prefix-list to apply to output packets +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy prefix-list $VAR(@)\" ";"prefix-list $VAR(@) doesn't exist" +update:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distribute-list prefix $VAR(@) out\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distribute-list prefix $VAR(@) out\" " diff --git a/templates/protocols/rip/interface/node.def b/templates/protocols/rip/interface/node.def index e9e6fc8e..c5c730c2 100644 --- a/templates/protocols/rip/interface/node.def +++ b/templates/protocols/rip/interface/node.def @@ -1,13 +1,13 @@ multi: type: txt -help: "Interface name" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ]; then \ - echo ethernet interface $(@) doesn\\'t exist on this system ; \ +help: Interface name +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ]; then \ + echo ethernet interface $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" -c \"network $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" -c \"no network $(@)\" " -#allowed: local -a array; -# array=( /sys/class/net/{eth,vmnet}* ) ; -# echo -n ${array[@]##*/} +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" -c \"network $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" -c \"no network $VAR(@)\" " +allowed: local -a array; + array=( /sys/class/net/{eth,vmnet}* ) ; + echo -n ${array[@]##*/} diff --git a/templates/protocols/rip/neighbor/node.def b/templates/protocols/rip/neighbor/node.def index c20ddc56..1b694564 100644 --- a/templates/protocols/rip/neighbor/node.def +++ b/templates/protocols/rip/neighbor/node.def @@ -1,8 +1,8 @@ multi: type: ipv4 -help: "Specify a neighbor router" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"neighbor $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no neighbor $(@)\"; " +help: Specify a neighbor router +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"neighbor $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no neighbor $VAR(@)\"; " diff --git a/templates/protocols/rip/network-distance/node.def b/templates/protocols/rip/network-distance/node.def index 480e1f26..1caa6b04 100644 --- a/templates/protocols/rip/network-distance/node.def +++ b/templates/protocols/rip/network-distance/node.def @@ -1,18 +1,18 @@ tag: type: ipv4net -help: "Source network" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -commit: $(./distance/) != ""; "Must specify distance for network $(@)" -delete: "touch /tmp/rip-dist.\\$PPID" -end: "if [ -n \"$(./access-list/@)\" ]; then \ - ACL=\"$(./access-list/@)\"; \ +help: Source network +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +commit:expression: $VAR(./distance/) != ""; "Must specify distance for network $VAR(@)" +delete:expression: "touch /tmp/rip-dist.$PPID" +end:expression: "if [ -n \"$VAR(./access-list/@)\" ]; then \ + ACL=\"$VAR(./access-list/@)\"; \ fi; \ - if [ -f \"/tmp/rip-dist.\\$PPID\" ]; then \ - dist=\\$(cat /tmp/rip-network-distance.\\$PPID); \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no distance \\$dist $(@) \\$ACL \" ; - rm -f \"/tmp/rip-dist.\\$PPID\"; + if [ -f \"/tmp/rip-dist.$PPID\" ]; then \ + dist=$(cat /tmp/rip-network-distance.$PPID); \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no distance $dist $VAR(@) $ACL \" ; + rm -f \"/tmp/rip-dist.$PPID\"; else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"distance $(./distance/@) $(@) \\$ACL \" ; + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"distance $VAR(./distance/@) $VAR(@) $ACL \" ; fi; " diff --git a/templates/protocols/rip/network-distance/node.tag/access-list/node.def b/templates/protocols/rip/network-distance/node.tag/access-list/node.def index ab225ff4..3003e718 100644 --- a/templates/protocols/rip/network-distance/node.tag/access-list/node.def +++ b/templates/protocols/rip/network-distance/node.tag/access-list/node.def @@ -1,3 +1,3 @@ type: txt -help: "Access list" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $(@)\" ";"access-list $(@) doesn't exist" +help: Access list +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy access-list $VAR(@)\" ";"access-list $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/network-distance/node.tag/distance/node.def b/templates/protocols/rip/network-distance/node.tag/distance/node.def index da83eed5..96d3042e 100644 --- a/templates/protocols/rip/network-distance/node.tag/distance/node.def +++ b/templates/protocols/rip/network-distance/node.tag/distance/node.def @@ -1,6 +1,6 @@ type: u32 -help: "Administrative distance for network" -syntax: $(@) >= 1 && $(@) <= 255; "must be between 1 and 255" -delete: "echo $(@) > /tmp/rip-network-distance.\\$PPID" -#comp_help: Enter a distance valude between 1-255 +help: Administrative distance for network +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "must be between 1 and 255" +delete:expression: "echo $VAR(@) > /tmp/rip-network-distance.$PPID" +comp_help: Enter a distance valude between 1-255 diff --git a/templates/protocols/rip/network-distance/node.tag/node.def b/templates/protocols/rip/network-distance/node.tag/node.def index c82cb253..7e9c8d59 100644 --- a/templates/protocols/rip/network-distance/node.tag/node.def +++ b/templates/protocols/rip/network-distance/node.tag/node.def @@ -1 +1 @@ -help: "Set distance for a given network" +help: Set distance for a given network diff --git a/templates/protocols/rip/network/node.def b/templates/protocols/rip/network/node.def index 7feec8ae..e01ee3fe 100644 --- a/templates/protocols/rip/network/node.def +++ b/templates/protocols/rip/network/node.def @@ -1,8 +1,8 @@ multi: type: ipv4net -help: "RIP network" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"network $(@)\"; " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no network $(@)\"; " +help: RIP network +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"network $VAR(@)\"; " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no network $VAR(@)\"; " diff --git a/templates/protocols/rip/node.def b/templates/protocols/rip/node.def index 888686cf..c5442b5c 100644 --- a/templates/protocols/rip/node.def +++ b/templates/protocols/rip/node.def @@ -1,4 +1,4 @@ -help: "RIP options" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router rip\" " +help: RIP options +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no router rip\" " diff --git a/templates/protocols/rip/passive-interface/node.def b/templates/protocols/rip/passive-interface/node.def index 85a1bf22..5a4001b5 100644 --- a/templates/protocols/rip/passive-interface/node.def +++ b/templates/protocols/rip/passive-interface/node.def @@ -1,25 +1,25 @@ multi: type: txt -help: "Suppress routing updates on an interface" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ] && [ x$(@) != xdefault ]; then \ - echo ethernet interface $(@) doesn\\'t exist on this system ; \ +help: Suppress routing updates on an interface +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ] && [ x$VAR(@) != xdefault ]; then \ + echo ethernet interface $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -update: "if [ x$(x) == xdefault ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +update:expression: "if [ x$VAR(x) == xdefault ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"passive-interface default\"; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"passive-interface $(@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"passive-interface $VAR(@)\"; \ fi; " -delete: "if [ x$(x) == xdefault ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +delete:expression: "if [ x$VAR(x) == xdefault ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no passive-interface default\"; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no passive-interface $(@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no passive-interface $VAR(@)\"; \ fi; " -#allowed: local -a array; -# array=( /sys/class/net/{eth,vmnet}* ) ; -# echo -n ${array[@]##*/} +allowed: local -a array; + array=( /sys/class/net/{eth,vmnet}* ) ; + echo -n ${array[@]##*/} diff --git a/templates/protocols/rip/redistribute/bgp/metric/node.def b/templates/protocols/rip/redistribute/bgp/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/rip/redistribute/bgp/metric/node.def +++ b/templates/protocols/rip/redistribute/bgp/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/rip/redistribute/bgp/node.def b/templates/protocols/rip/redistribute/bgp/node.def index d69e22b2..84317dcd 100644 --- a/templates/protocols/rip/redistribute/bgp/node.def +++ b/templates/protocols/rip/redistribute/bgp/node.def @@ -1,16 +1,16 @@ -help: "Redistribute BGP routes" -delete: "touch /tmp/rip-redist-bgp.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Redistribute BGP routes +delete:expression: "touch /tmp/rip-redist-bgp.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no redistribute bgp \"; \ - if [ -f \"/tmp/rip-redist-bgp.\\$PPID\" ]; then \ - rm -rf /tmp/rip-redist-bgp.\\$PPID; \ + if [ -f \"/tmp/rip-redist-bgp.$PPID\" ]; then \ + rm -rf /tmp/rip-redist-bgp.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"redistribute bgp \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"redistribute bgp $COND\"; \ fi; " diff --git a/templates/protocols/rip/redistribute/bgp/route-map/node.def b/templates/protocols/rip/redistribute/bgp/route-map/node.def index f6e81288..a56f5668 100644 --- a/templates/protocols/rip/redistribute/bgp/route-map/node.def +++ b/templates/protocols/rip/redistribute/bgp/route-map/node.def @@ -1,4 +1,4 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/redistribute/connected/metric/node.def b/templates/protocols/rip/redistribute/connected/metric/node.def index d7ca3c34..8234167e 100644 --- a/templates/protocols/rip/redistribute/connected/metric/node.def +++ b/templates/protocols/rip/redistribute/connected/metric/node.def @@ -1,6 +1,6 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/rip/redistribute/connected/node.def b/templates/protocols/rip/redistribute/connected/node.def index 46dc83f3..a7157811 100644 --- a/templates/protocols/rip/redistribute/connected/node.def +++ b/templates/protocols/rip/redistribute/connected/node.def @@ -1,16 +1,16 @@ -help: "Redistribute connected routes" -delete: "touch /tmp/rip-redist-connected.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Redistribute connected routes +delete:expression: "touch /tmp/rip-redist-connected.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no redistribute connected \"; \ - if [ -f \"/tmp/rip-redist-connected.\\$PPID\" ]; then \ - rm -rf /tmp/rip-redist-connected.\\$PPID; \ + if [ -f \"/tmp/rip-redist-connected.$PPID\" ]; then \ + rm -rf /tmp/rip-redist-connected.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"redistribute connected \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"redistribute connected $COND\"; \ fi; " diff --git a/templates/protocols/rip/redistribute/connected/route-map/node.def b/templates/protocols/rip/redistribute/connected/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/rip/redistribute/connected/route-map/node.def +++ b/templates/protocols/rip/redistribute/connected/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/redistribute/kernel/metric/node.def b/templates/protocols/rip/redistribute/kernel/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/rip/redistribute/kernel/metric/node.def +++ b/templates/protocols/rip/redistribute/kernel/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/rip/redistribute/kernel/node.def b/templates/protocols/rip/redistribute/kernel/node.def index 6ac0b1ab..ca9a4412 100644 --- a/templates/protocols/rip/redistribute/kernel/node.def +++ b/templates/protocols/rip/redistribute/kernel/node.def @@ -1,16 +1,16 @@ -help: "Redistribute kernel routes" -delete: "touch /tmp/rip-redist-kernel.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Redistribute kernel routes +delete:expression: "touch /tmp/rip-redist-kernel.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no redistribute kernel \"; \ - if [ -f \"/tmp/rip-redist-kernel.\\$PPID\" ]; then \ - rm -rf /tmp/rip-redist-kernel.\\$PPID; \ + if [ -f \"/tmp/rip-redist-kernel.$PPID\" ]; then \ + rm -rf /tmp/rip-redist-kernel.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"redistribute kernel \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"redistribute kernel $COND\"; \ fi; " diff --git a/templates/protocols/rip/redistribute/kernel/route-map/node.def b/templates/protocols/rip/redistribute/kernel/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/rip/redistribute/kernel/route-map/node.def +++ b/templates/protocols/rip/redistribute/kernel/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/redistribute/node.def b/templates/protocols/rip/redistribute/node.def index e46c9122..00eefa88 100644 --- a/templates/protocols/rip/redistribute/node.def +++ b/templates/protocols/rip/redistribute/node.def @@ -1 +1 @@ -help: "Redistribute information from another routing protocol" +help: Redistribute information from another routing protocol diff --git a/templates/protocols/rip/redistribute/ospf/metric/node.def b/templates/protocols/rip/redistribute/ospf/metric/node.def index 01a2dda7..80d13b5e 100644 --- a/templates/protocols/rip/redistribute/ospf/metric/node.def +++ b/templates/protocols/rip/redistribute/ospf/metric/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/rip/redistribute/ospf/node.def b/templates/protocols/rip/redistribute/ospf/node.def index cc95c6a5..04c43c83 100644 --- a/templates/protocols/rip/redistribute/ospf/node.def +++ b/templates/protocols/rip/redistribute/ospf/node.def @@ -1,17 +1,17 @@ -help: "Redistribute OSPF routes" -delete: "touch /tmp/rip-redist-ospf.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Redistribute OSPF routes +delete:expression: "touch /tmp/rip-redist-ospf.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no redistribute ospf \"; \ - if [ -f \"/tmp/rip-redist-ospf.\\$PPID\" ]; then \ - rm -rf /tmp/rip-redist-ospf.\\$PPID; \ + if [ -f \"/tmp/rip-redist-ospf.$PPID\" ]; then \ + rm -rf /tmp/rip-redist-ospf.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"redistribute ospf \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"redistribute ospf $COND\"; \ fi; " diff --git a/templates/protocols/rip/redistribute/ospf/route-map/node.def b/templates/protocols/rip/redistribute/ospf/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/rip/redistribute/ospf/route-map/node.def +++ b/templates/protocols/rip/redistribute/ospf/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/redistribute/static/metric/node.def b/templates/protocols/rip/redistribute/static/metric/node.def index 270a810e..549cfdf1 100644 --- a/templates/protocols/rip/redistribute/static/metric/node.def +++ b/templates/protocols/rip/redistribute/static/metric/node.def @@ -1,3 +1,3 @@ type: u32 -help: "Metric for redistributed routes" -syntax: $(@) >= 1 && $(@) <= 16; "metric must be between 1 and 16" +help: Metric for redistributed routes +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 16; "metric must be between 1 and 16" diff --git a/templates/protocols/rip/redistribute/static/node.def b/templates/protocols/rip/redistribute/static/node.def index a4a7cbb7..ab170994 100644 --- a/templates/protocols/rip/redistribute/static/node.def +++ b/templates/protocols/rip/redistribute/static/node.def @@ -1,16 +1,16 @@ -help: "Redistribute static routes" -delete: "touch /tmp/rip-redist-static.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Redistribute static routes +delete:expression: "touch /tmp/rip-redist-static.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no redistribute static \"; \ - if [ -f \"/tmp/rip-redist-static.\\$PPID\" ]; then \ - rm -rf /tmp/rip-redist-static.\\$PPID; \ + if [ -f \"/tmp/rip-redist-static.$PPID\" ]; then \ + rm -rf /tmp/rip-redist-static.$PPID; \ else \ - if [ -n \"$(./metric/@)\" ]; then \ - COND=\"metric $(./metric/@)\"; + if [ -n \"$VAR(./metric/@)\" ]; then \ + COND=\"metric $VAR(./metric/@)\"; fi; \ - if [ -n \"$(./route-map/@)\" ]; then \ - COND=\"\\$COND route-map $(./route-map/@)\"; \ + if [ -n \"$VAR(./route-map/@)\" ]; then \ + COND=\"$COND route-map $VAR(./route-map/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"redistribute static \\$COND\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"redistribute static $COND\"; \ fi; " diff --git a/templates/protocols/rip/redistribute/static/route-map/node.def b/templates/protocols/rip/redistribute/static/route-map/node.def index 5ce5f0ab..f2c6f7c2 100644 --- a/templates/protocols/rip/redistribute/static/route-map/node.def +++ b/templates/protocols/rip/redistribute/static/route-map/node.def @@ -1,3 +1,3 @@ type: txt -help: "Route map reference" -commit: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $(@)\" ";"route-map $(@) doesn't exist" +help: Route map reference +commit:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --exists \"policy route-map $VAR(@)\" ";"route-map $VAR(@) doesn't exist" diff --git a/templates/protocols/rip/route/node.def b/templates/protocols/rip/route/node.def index 5983d3a8..bb2be03f 100644 --- a/templates/protocols/rip/route/node.def +++ b/templates/protocols/rip/route/node.def @@ -1,9 +1,9 @@ multi: type: ipv4net -help: "RIP static route configuration" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" -create: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"route $(@)\" " -delete: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"no route $(@)\" " +help: RIP static route configuration +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" +create:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"route $VAR(@)\" " +delete:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"no route $VAR(@)\" " diff --git a/templates/protocols/rip/timers/garbage-collection/node.def b/templates/protocols/rip/timers/garbage-collection/node.def index 3a70f5b6..c30b35e4 100644 --- a/templates/protocols/rip/timers/garbage-collection/node.def +++ b/templates/protocols/rip/timers/garbage-collection/node.def @@ -1,6 +1,6 @@ type: u32 default: 120 -help: "Garbage collection timer. Default is 120." -syntax: $(@) >= 5 && $(@) <= 2147483647; "Garbage collection timer must be between 5 and 2147483647" +help: Garbage collection timer. Default is 120. +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 2147483647; "Garbage collection timer must be between 5 and 2147483647" diff --git a/templates/protocols/rip/timers/node.def b/templates/protocols/rip/timers/node.def index 08bb0234..94a46fb6 100644 --- a/templates/protocols/rip/timers/node.def +++ b/templates/protocols/rip/timers/node.def @@ -1,11 +1,11 @@ -help: "Set RIP timer values" -delete: "touch /tmp/rip-timers.\\$PPID" -end: "\\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ +help: Set RIP timer values +delete:expression: "touch /tmp/rip-timers.$PPID" +end:expression: "${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ -c \"no timers basic\"; \ - if [ -f \"/tmp/rip-timers.\\$PPID\" ]; then \ - rm -rf /tmp/rip-timers.\\$PPID; \ + if [ -f \"/tmp/rip-timers.$PPID\" ]; then \ + rm -rf /tmp/rip-timers.$PPID; \ else \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ - -c \"timers basic $(./update/@) $(./timeout/@) $(./garbage-collection/@)\"; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"router rip\" \ + -c \"timers basic $VAR(./update/@) $VAR(./timeout/@) $VAR(./garbage-collection/@)\"; \ fi; " diff --git a/templates/protocols/rip/timers/timeout/node.def b/templates/protocols/rip/timers/timeout/node.def index 2b01255f..cc7f2fe5 100644 --- a/templates/protocols/rip/timers/timeout/node.def +++ b/templates/protocols/rip/timers/timeout/node.def @@ -1,4 +1,4 @@ type: u32 default: 180 -help: "Routing information timeout timer. Default is 180." -syntax: $(@) >= 5 && $(@) <= 2147483647; "Timeout timer must be between 5 and 2147483647" +help: Routing information timeout timer. Default is 180. +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 2147483647; "Timeout timer must be between 5 and 2147483647" diff --git a/templates/protocols/rip/timers/update/node.def b/templates/protocols/rip/timers/update/node.def index e1aa59e7..24d6bc09 100644 --- a/templates/protocols/rip/timers/update/node.def +++ b/templates/protocols/rip/timers/update/node.def @@ -1,5 +1,5 @@ type: u32 default: 30 -help: "Routing table update timer in seconds. Default is 30." -syntax: $(@) >= 5 && $(@) <= 2147483647; "Update timer must be between 5 and 2147483647" +help: Routing table update timer in seconds. Default is 30. +syntax:expression: $VAR(@) >= 5 && $VAR(@) <= 2147483647; "Update timer must be between 5 and 2147483647" diff --git a/templates/protocols/static/interface-route/node.def b/templates/protocols/static/interface-route/node.def index 035417e3..56992140 100644 --- a/templates/protocols/static/interface-route/node.def +++ b/templates/protocols/static/interface-route/node.def @@ -1,4 +1,4 @@ tag: type: ipv4net -help: "Configure an interface-based static route" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" +help: Configure an interface-based static route +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" diff --git a/templates/protocols/static/interface-route/node.tag/blackhole/distance/node.def b/templates/protocols/static/interface-route/node.tag/blackhole/distance/node.def index 938aea1a..ac8083af 100644 --- a/templates/protocols/static/interface-route/node.tag/blackhole/distance/node.def +++ b/templates/protocols/static/interface-route/node.tag/blackhole/distance/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Distance value for this route" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between (1-255)" -#comp_help: <1-255> Distance for this route +help: Distance value for this route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between (1-255)" +comp_help: <1-255> Distance for this route diff --git a/templates/protocols/static/interface-route/node.tag/blackhole/node.def b/templates/protocols/static/interface-route/node.tag/blackhole/node.def index 5bfab1a8..d8e65ef4 100644 --- a/templates/protocols/static/interface-route/node.tag/blackhole/node.def +++ b/templates/protocols/static/interface-route/node.tag/blackhole/node.def @@ -1,11 +1,11 @@ -help: "Silently discard pkts when matched" -delete: "touch /tmp/static.\\$PPID" -end: "if [ -f \"/tmp/static.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $(../@) null0\" ; \ - rm /tmp/static.\\$PPID; \ +help: Silently discard pkts when matched +delete:expression: "touch /tmp/static.$PPID" +end:expression: "if [ -f \"/tmp/static.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $VAR(../@) null0\" ; \ + rm /tmp/static.$PPID; \ else \ - if [ -n \"$(./distance/@)\" ]; then \ - DIST=\"$(./distance/@)\"; \ + if [ -n \"$VAR(./distance/@)\" ]; then \ + DIST=\"$VAR(./distance/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $(../@) null0 \\$DIST \" ; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $VAR(../@) null0 $DIST \" ; \ fi; " diff --git a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.def b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.def index f39457b7..6f3b606a 100644 --- a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.def +++ b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.def @@ -1,19 +1,19 @@ tag: type: txt -help: "Configure the next-hop interface" -syntax: exec " \ - if [ -z \"`ip addr | grep $(@) `\" ]; then \ - echo ethernet interface $(@) doesn\\'t exist on this system ; \ +help: Configure the next-hop interface +syntax:expression: exec " \ + if [ -z \"`ip addr | grep $VAR(@) `\" ]; then \ + echo ethernet interface $VAR(@) doesn\\'t exist on this system ; \ exit 1 ; \ fi ; " -delete: "touch /tmp/static.\\$PPID" -end: "if [ -f \"/tmp/static.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $(../@) $(@)\" ; \ - rm /tmp/static.\\$PPID; \ +delete:expression: "touch /tmp/static.$PPID" +end:expression: "if [ -f \"/tmp/static.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $VAR(../@) $VAR(@)\" ; \ + rm /tmp/static.$PPID; \ else \ - if [ -n \"$(./distance/@)\" ]; then \ - DIST=\"$(./distance/@)\"; \ + if [ -n \"$VAR(./distance/@)\" ]; then \ + DIST=\"$VAR(./distance/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $(../@) $(@) \\$DIST \" ; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $VAR(../@) $VAR(@) $DIST \" ; \ fi; " diff --git a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/distance/node.def b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/distance/node.def index 938aea1a..ac8083af 100644 --- a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/distance/node.def +++ b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/distance/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Distance value for this route" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between (1-255)" -#comp_help: <1-255> Distance for this route +help: Distance value for this route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between (1-255)" +comp_help: <1-255> Distance for this route diff --git a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/node.def b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/node.def index f02c8e46..0422e89c 100644 --- a/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/node.def +++ b/templates/protocols/static/interface-route/node.tag/next-hop-interface/node.tag/node.def @@ -1 +1 @@ -help: "Enter next-hop interface" +help: Enter next-hop interface diff --git a/templates/protocols/static/interface-route/node.tag/node.def b/templates/protocols/static/interface-route/node.tag/node.def index 40651f1a..e6893719 100644 --- a/templates/protocols/static/interface-route/node.tag/node.def +++ b/templates/protocols/static/interface-route/node.tag/node.def @@ -1,2 +1,2 @@ -help: "IP network" -commit: $(./next-hop-interface/) != "" || $(./blackhole/) != ""; "Must add either a next-hop-interface or blackhole for route $(@)" +help: IP network +commit:expression: $VAR(./next-hop-interface/) != "" || $VAR(./blackhole/) != ""; "Must add either a next-hop-interface or blackhole for route $VAR(@)" diff --git a/templates/protocols/static/node.def b/templates/protocols/static/node.def index 6c673799..0cb6cd0c 100644 --- a/templates/protocols/static/node.def +++ b/templates/protocols/static/node.def @@ -1,3 +1,3 @@ -help: "Static route configuration" +help: Static route configuration diff --git a/templates/protocols/static/route/node.def b/templates/protocols/static/route/node.def index 63e2c6c7..be26c621 100644 --- a/templates/protocols/static/route/node.def +++ b/templates/protocols/static/route/node.def @@ -1,4 +1,4 @@ tag: type: ipv4net -help: "Configure a static route" -syntax: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $(@)" +help: Configure a static route +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" diff --git a/templates/protocols/static/route/node.tag/blackhole/distance/node.def b/templates/protocols/static/route/node.tag/blackhole/distance/node.def index 938aea1a..ac8083af 100644 --- a/templates/protocols/static/route/node.tag/blackhole/distance/node.def +++ b/templates/protocols/static/route/node.tag/blackhole/distance/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Distance value for this route" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between (1-255)" -#comp_help: <1-255> Distance for this route +help: Distance value for this route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between (1-255)" +comp_help: <1-255> Distance for this route diff --git a/templates/protocols/static/route/node.tag/blackhole/node.def b/templates/protocols/static/route/node.tag/blackhole/node.def index 5bfab1a8..d8e65ef4 100644 --- a/templates/protocols/static/route/node.tag/blackhole/node.def +++ b/templates/protocols/static/route/node.tag/blackhole/node.def @@ -1,11 +1,11 @@ -help: "Silently discard pkts when matched" -delete: "touch /tmp/static.\\$PPID" -end: "if [ -f \"/tmp/static.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $(../@) null0\" ; \ - rm /tmp/static.\\$PPID; \ +help: Silently discard pkts when matched +delete:expression: "touch /tmp/static.$PPID" +end:expression: "if [ -f \"/tmp/static.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $VAR(../@) null0\" ; \ + rm /tmp/static.$PPID; \ else \ - if [ -n \"$(./distance/@)\" ]; then \ - DIST=\"$(./distance/@)\"; \ + if [ -n \"$VAR(./distance/@)\" ]; then \ + DIST=\"$VAR(./distance/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $(../@) null0 \\$DIST \" ; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $VAR(../@) null0 $DIST \" ; \ fi; " diff --git a/templates/protocols/static/route/node.tag/next-hop/node.def b/templates/protocols/static/route/node.tag/next-hop/node.def index 7d02f9d6..1540a0b4 100644 --- a/templates/protocols/static/route/node.tag/next-hop/node.def +++ b/templates/protocols/static/route/node.tag/next-hop/node.def @@ -1,13 +1,13 @@ tag: type: ipv4 -help: "Configure the next-hop router" -delete: "touch /tmp/static.\\$PPID" -end: "if [ -f \"/tmp/static.\\$PPID\" ]; then \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $(../@) $(@)\" ; \ - rm /tmp/static.\\$PPID; \ +help: Configure the next-hop router +delete:expression: "touch /tmp/static.$PPID" +end:expression: "if [ -f \"/tmp/static.$PPID\" ]; then \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $VAR(../@) $VAR(@)\" ; \ + rm /tmp/static.$PPID; \ else \ - if [ -n \"$(./distance/@)\" ]; then \ - DIST=\"$(./distance/@)\"; \ + if [ -n \"$VAR(./distance/@)\" ]; then \ + DIST=\"$VAR(./distance/@)\"; \ fi; \ - \\${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $(../@) $(@) \\$DIST \" ; \ + ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $VAR(../@) $VAR(@) $DIST \" ; \ fi; " diff --git a/templates/protocols/static/route/node.tag/next-hop/node.tag/distance/node.def b/templates/protocols/static/route/node.tag/next-hop/node.tag/distance/node.def index 938aea1a..ac8083af 100644 --- a/templates/protocols/static/route/node.tag/next-hop/node.tag/distance/node.def +++ b/templates/protocols/static/route/node.tag/next-hop/node.tag/distance/node.def @@ -1,4 +1,4 @@ type: u32 -help: "Distance value for this route" -syntax: $(@) >= 1 && $(@) <= 255; "Must be between (1-255)" -#comp_help: <1-255> Distance for this route +help: Distance value for this route +syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "Must be between (1-255)" +comp_help: <1-255> Distance for this route diff --git a/templates/protocols/static/route/node.tag/next-hop/node.tag/node.def b/templates/protocols/static/route/node.tag/next-hop/node.tag/node.def index 45bb111e..7a5e624b 100644 --- a/templates/protocols/static/route/node.tag/next-hop/node.tag/node.def +++ b/templates/protocols/static/route/node.tag/next-hop/node.tag/node.def @@ -1,2 +1,2 @@ -help: "Enter next-hop router" +help: Enter next-hop router diff --git a/templates/protocols/static/route/node.tag/node.def b/templates/protocols/static/route/node.tag/node.def index 56b1f7c8..ce1324d8 100644 --- a/templates/protocols/static/route/node.tag/node.def +++ b/templates/protocols/static/route/node.tag/node.def @@ -1,3 +1,3 @@ -help: "IP network" -commit: $(./next-hop/) != "" || $(./blackhole/) != ""; "Must add either a next-hop or blackhole for route $(@)" +help: IP network +commit:expression: $VAR(./next-hop/) != "" || $VAR(./blackhole/) != ""; "Must add either a next-hop or blackhole for route $VAR(@)" |