summaryrefslogtreecommitdiff
path: root/templates/interfaces
diff options
context:
space:
mode:
authorStig Thormodsrud <stig@vyatta.com>2008-01-21 19:00:21 -0800
committerStig Thormodsrud <stig@vyatta.com>2008-01-21 19:00:21 -0800
commitc3f28ce3332dfa5ccc3ac658df876d7cd444eea5 (patch)
tree119ca2b780798772ab7980f7e01ceae3be93c7f1 /templates/interfaces
parentb45bba4286e83f8babcd70eef908f2ea2f8fff3c (diff)
downloadvyatta-cfg-system-c3f28ce3332dfa5ccc3ac658df876d7cd444eea5.tar.gz
vyatta-cfg-system-c3f28ce3332dfa5ccc3ac658df876d7cd444eea5.zip
All vrrp to be configured on vif
Diffstat (limited to 'templates/interfaces')
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/bridge/node.def12
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/cost/node.def4
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/priority/node.def4
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/node.def3
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.def8
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def6
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def3
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def6
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/description/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/node.def1
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def7
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/priority/node.def5
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/sync-group/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def3
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def4
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def7
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/description/node.def2
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def5
-rw-r--r--templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/priority/node.def2
22 files changed, 88 insertions, 4 deletions
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/bridge/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/bridge/node.def
new file mode 100644
index 00000000..d655f6bc
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/bridge/node.def
@@ -0,0 +1,12 @@
+type: txt
+help: "Add this interface to a bridge-group"
+syntax: exec " \
+ if [ -z \"`sudo brctl show | grep $(@) `\" ]; then \
+ echo bridge interface $(@) doesn\\'t exist on this system ; \
+ exit 1 ; \
+ fi ; "
+update: "sudo brctl addif $(@) $(../../../../@).$(../../@)"
+delete: "sudo brctl delif $(@) $(../../../../@).$(../../@)"
+#allowed: local -a array ;
+# array=( /sys/class/net/br* ) ;
+# echo -n ${array[@]##*/}
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/cost/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/cost/node.def
new file mode 100644
index 00000000..1c2bbde1
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/cost/node.def
@@ -0,0 +1,4 @@
+type: u32
+help: "Set the path cost for this port"
+commit: $(../bridge/) != ""; "Must configure bridge interface"
+update: "sudo brctl setpathcost $(../../@) $(@)"
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/node.def
new file mode 100644
index 00000000..b76b5d71
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/node.def
@@ -0,0 +1,2 @@
+help: "Add this interface to a bridge group"
+commit: $(./bridge/) != ""; "Must set the bridge interface"
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/priority/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/priority/node.def
new file mode 100644
index 00000000..d254b082
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/bridge-group/priority/node.def
@@ -0,0 +1,4 @@
+type: u32
+help: "Set the path priority for this port"
+commit: $(../bridge/) != ""; "Must configure bridge interface"
+update: "sudo brctl setportprio $(../../@) $(@)"
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/node.def
new file mode 100644
index 00000000..b21963c6
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/node.def
@@ -0,0 +1,3 @@
+help: "Configure VRRP"
+commit: $(../address/) != ""; "Must define a primary IP address on $(../../@) vif $(../@)"
+end: "sudo /opt/vyatta/sbin/vyatta-keepalived.pl --vrrp-action update --intf $(../../@).$(../@) "
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.def
new file mode 100644
index 00000000..e3e0b083
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.def
@@ -0,0 +1,8 @@
+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 $(@) "
+#comp_help: possible completions
+# <1-255> VRRP group number
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def
new file mode 100644
index 00000000..12c9f0f4
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/advertise-interval/node.def
@@ -0,0 +1,6 @@
+type: u32
+default: 1
+help: "Configure advertise interval"
+syntax: $(@) >= 1 && $(@) <=255; "Advertise interval must be between 1-255"
+#comp_help: possible completions
+# <1-255> Set advertise interval (default 1)
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/node.def b/templates/interfaces/ethernet/node.tag/vif/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/vif/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/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/password/node.def b/templates/interfaces/ethernet/node.tag/vif/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/vif/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/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def
new file mode 100644
index 00000000..9f624356
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/authentication/type/node.def
@@ -0,0 +1,6 @@
+type: txt
+help: "Authentication type"
+syntax: $(@) in "simple", "AH", "ah"; "authentication must be simple or AH"
+#comp_help: possible completions:
+# simple Set simple password mode
+# AH Set IP Authentication Header mode
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/description/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/description/node.def
new file mode 100644
index 00000000..d457185a
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/description/node.def
@@ -0,0 +1,2 @@
+type: txt
+help: "Description for this interface"
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/node.def
new file mode 100644
index 00000000..a4f3c074
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/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/vif/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def
new file mode 100644
index 00000000..a0b0efa2
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/preempt/node.def
@@ -0,0 +1,7 @@
+type: txt
+help: "Preempt mode"
+default: "true"
+syntax: $(@) in "true", "false"; "preempt must be true or false"
+#comp_help: possible completions:
+# true (default)
+# false
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/priority/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/priority/node.def
new file mode 100644
index 00000000..413bba15
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/priority/node.def
@@ -0,0 +1,5 @@
+type: u32
+syntax: $(@) >= 0 &&$(@) <= 255; "priority must be between 1-255"
+help: "Priority"
+#comp_help: possible completions:
+# <1-255> Set Priority
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/sync-group/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/sync-group/node.def
new file mode 100644
index 00000000..5fa24b92
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/sync-group/node.def
@@ -0,0 +1,2 @@
+type: txt
+help: "Add this vrrp group to a sync group"
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def b/templates/interfaces/ethernet/node.tag/vif/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/vif/node.tag/vrrp/vrrp-group/node.tag/virtual-address/node.def
@@ -0,0 +1,3 @@
+multi:
+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 dfb9c6a2..a61a022f 100644
--- a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def
+++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.def
@@ -4,3 +4,5 @@ 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 $(@) "
+#comp_help: possible completions
+# <1-255> VRRP group number
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
index edfbc3a4..12c9f0f4 100644
--- 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
@@ -1,4 +1,6 @@
type: u32
default: 1
help: "Configure advertise interval"
-syntax: $(@) > 0 && $(@) <=255; "Advertise interval must be between 1-255"
+syntax: $(@) >= 1 && $(@) <=255; "Advertise interval must be between 1-255"
+#comp_help: possible completions
+# <1-255> Set advertise interval (default 1)
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
index 72e53f4b..9f624356 100644
--- 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
@@ -1,3 +1,6 @@
type: txt
-help: "Authentication type PASS|AH"
-syntax: $(@) in "PASS", "pass", "AH", "ah"; "authentication must be PASS or AH"
+help: "Authentication type"
+syntax: $(@) in "simple", "AH", "ah"; "authentication must be simple or AH"
+#comp_help: possible completions:
+# simple Set simple password mode
+# AH Set IP Authentication Header mode
diff --git a/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/description/node.def b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/description/node.def
new file mode 100644
index 00000000..d457185a
--- /dev/null
+++ b/templates/interfaces/ethernet/node.tag/vrrp/vrrp-group/node.tag/description/node.def
@@ -0,0 +1,2 @@
+type: txt
+help: "Description for this interface"
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
index a9869373..a0b0efa2 100644
--- 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
@@ -1,4 +1,7 @@
type: txt
-help: "Preempt (true or false)"
+help: "Preempt mode"
default: "true"
syntax: $(@) in "true", "false"; "preempt must be true or false"
+#comp_help: possible completions:
+# true (default)
+# 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
index 3f7aacbf..413bba15 100644
--- 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
@@ -1,3 +1,5 @@
type: u32
syntax: $(@) >= 0 &&$(@) <= 255; "priority must be between 1-255"
help: "Priority"
+#comp_help: possible completions:
+# <1-255> Set Priority