From 1802eb010fb9b382dde4d3e1574fd578027c7dc0 Mon Sep 17 00:00:00 2001 From: Stig Thormodsrud Date: Tue, 18 Dec 2007 09:53:24 -0800 Subject: - Add support for multiple vrrp groups per interface. - Add support for multiple VIPs per vrrp group. --- .../interfaces/ethernet/node.tag/vrrp/advertise-interval/node.def | 4 ---- templates/interfaces/ethernet/node.tag/vrrp/authentication/node.def | 3 --- .../ethernet/node.tag/vrrp/authentication/password/node.def | 2 -- .../interfaces/ethernet/node.tag/vrrp/authentication/type/node.def | 3 --- templates/interfaces/ethernet/node.tag/vrrp/node.def | 2 -- templates/interfaces/ethernet/node.tag/vrrp/preempt/node.def | 4 ---- templates/interfaces/ethernet/node.tag/vrrp/priority/node.def | 3 --- templates/interfaces/ethernet/node.tag/vrrp/virtual-address/node.def | 2 -- templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def | 4 +++- .../node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def | 4 ++++ .../node.tag/vrrp/vrrp-group/node.tag/authentication/node.def | 3 +++ .../vrrp/vrrp-group/node.tag/authentication/password/node.def | 2 ++ .../node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def | 3 +++ .../interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/node.def | 1 + .../ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def | 4 ++++ .../ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def | 3 +++ .../node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def | 3 +++ 17 files changed, 26 insertions(+), 24 deletions(-) delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/advertise-interval/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/authentication/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/authentication/password/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/authentication/type/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/preempt/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/priority/node.def delete mode 100644 templates/interfaces/ethernet/node.tag/vrrp/virtual-address/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def create mode 100644 templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def (limited to 'templates/interfaces') diff --git a/templates/interfaces/ethernet/node.tag/vrrp/advertise-interval/node.def b/templates/interfaces/ethernet/node.tag/vrrp/advertise-interval/node.def deleted file mode 100644 index edfbc3a4..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/advertise-interval/node.def +++ /dev/null @@ -1,4 +0,0 @@ -type: u32 -default: 1 -help: "Configure advertise interval" -syntax: $(@) > 0 && $(@) <=255; "Advertise interval must be between 1-255" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/authentication/node.def b/templates/interfaces/ethernet/node.tag/vrrp/authentication/node.def deleted file mode 100644 index e3120d51..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/authentication/node.def +++ /dev/null @@ -1,3 +0,0 @@ -help: "Configure authentication" -commit: $(./type/@) != ""; "You must set a authentication type" -commit: $(./password/@) != ""; "You must set a authentication password" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/authentication/password/node.def b/templates/interfaces/ethernet/node.tag/vrrp/authentication/password/node.def deleted file mode 100644 index 87855962..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/authentication/password/node.def +++ /dev/null @@ -1,2 +0,0 @@ -type: txt -help: "Password text" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/authentication/type/node.def b/templates/interfaces/ethernet/node.tag/vrrp/authentication/type/node.def deleted file mode 100644 index 72e53f4b..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/authentication/type/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: txt -help: "Authentication type PASS|AH" -syntax: $(@) in "PASS", "pass", "AH", "ah"; "authentication must be PASS or AH" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/node.def b/templates/interfaces/ethernet/node.tag/vrrp/node.def index de3253a5..2c8cc58a 100644 --- a/templates/interfaces/ethernet/node.tag/vrrp/node.def +++ b/templates/interfaces/ethernet/node.tag/vrrp/node.def @@ -1,5 +1,3 @@ help: "Configure VRRP" commit: $(../address/) != ""; "Must define a primary IP address on $(../@)" -commit: $(virtual-address/) != ""; "Must define the virtual-address for vrrp-group $(../vrrp-group/@)" end: "sudo /opt/vyatta/sbin/vyatta-keepalived.pl --vrrp-action update --intf $(../@) " - diff --git a/templates/interfaces/ethernet/node.tag/vrrp/preempt/node.def b/templates/interfaces/ethernet/node.tag/vrrp/preempt/node.def deleted file mode 100644 index a9869373..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/preempt/node.def +++ /dev/null @@ -1,4 +0,0 @@ -type: txt -help: "Preempt (true or false)" -default: "true" -syntax: $(@) in "true", "false"; "preempt must be true or false" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/priority/node.def b/templates/interfaces/ethernet/node.tag/vrrp/priority/node.def deleted file mode 100644 index 3f7aacbf..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/priority/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: u32 -syntax: $(@) >= 0 &&$(@) <= 255; "priority must be between 1-255" -help: "Priority" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/virtual-address/node.def b/templates/interfaces/ethernet/node.tag/vrrp/virtual-address/node.def deleted file mode 100644 index badf657e..00000000 --- a/templates/interfaces/ethernet/node.tag/vrrp/virtual-address/node.def +++ /dev/null @@ -1,2 +0,0 @@ -type: ipv4 -help: "Configure virtual address" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def index fe9690d8..d2f231e7 100644 --- a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def @@ -1,4 +1,6 @@ +tag: type: u32 syntax: $(@) >= 0 && $(@) <= 255; "VRRP group must be between 1-255" +commit: $(virtual-address/) != ""; "Must define the virtual-address for vrrp-group $(@)" help: "Configure VRRP group number" -delete: "sudo /opt/vyatta/sbin/vyatta-keepalived.pl --vrrp-action delete --intf $(../../@) --group $(@) " +delete: "sudo /opt/vyatta/sbin/vyatta-keepalived.pl --vrrp-action delete --intf $(../../../@) --group $(@) " diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def new file mode 100644 index 00000000..edfbc3a4 --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def @@ -0,0 +1,4 @@ +type: u32 +default: 1 +help: "Configure advertise interval" +syntax: $(@) > 0 && $(@) <=255; "Advertise interval must be between 1-255" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def new file mode 100644 index 00000000..e3120d51 --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def @@ -0,0 +1,3 @@ +help: "Configure authentication" +commit: $(./type/@) != ""; "You must set a authentication type" +commit: $(./password/@) != ""; "You must set a authentication password" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def new file mode 100644 index 00000000..87855962 --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def @@ -0,0 +1,2 @@ +type: txt +help: "Password text" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def new file mode 100644 index 00000000..72e53f4b --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def @@ -0,0 +1,3 @@ +type: txt +help: "Authentication type PASS|AH" +syntax: $(@) in "PASS", "pass", "AH", "ah"; "authentication must be PASS or AH" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/node.def new file mode 100644 index 00000000..a4f3c074 --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/node.def @@ -0,0 +1 @@ +help: "VRRP configuration for this VRRP group" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def new file mode 100644 index 00000000..a9869373 --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def @@ -0,0 +1,4 @@ +type: txt +help: "Preempt (true or false)" +default: "true" +syntax: $(@) in "true", "false"; "preempt must be true or false" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def new file mode 100644 index 00000000..3f7aacbf --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def @@ -0,0 +1,3 @@ +type: u32 +syntax: $(@) >= 0 &&$(@) <= 255; "priority must be between 1-255" +help: "Priority" diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def new file mode 100644 index 00000000..bcf9392f --- /dev/null +++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def @@ -0,0 +1,3 @@ +multi: +type: ipv4 +help: "Configure virtual address" -- cgit v1.2.3