summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2008-08-11 18:43:10 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2008-08-11 18:43:10 -0700
commit6a824168c957ec8739707bde71aaf404d250250d (patch)
treeabed96aa2526f3cdd7eae65737ff77fde06e7e0b /templates
parentb8f32d2b0f7d018aa71b05c98c873b6314f55baa (diff)
downloadvyatta-cfg-6a824168c957ec8739707bde71aaf404d250250d.tar.gz
vyatta-cfg-6a824168c957ec8739707bde71aaf404d250250d.zip
Replace vyatta-vtysh with vtysh
Diffstat (limited to 'templates')
-rw-r--r--templates/interfaces/ethernet/node.def7
-rw-r--r--templates/interfaces/ethernet/node.tag/vif/node.def12
2 files changed, 8 insertions, 11 deletions
diff --git a/templates/interfaces/ethernet/node.def b/templates/interfaces/ethernet/node.def
index 1c52675..5e3df91 100644
--- a/templates/interfaces/ethernet/node.def
+++ b/templates/interfaces/ethernet/node.def
@@ -6,10 +6,9 @@ syntax:expression: exec " \
echo Invalid ethernet interface [$VAR(@)]; \
exit 1 ; \
fi ; "
-update:expression: "sudo ip link set $VAR(@) up" ; "Error enabling dev $VAR(@)"
-update:expression: "vyatta-vtysh -c \"configure terminal\" -c \"interface $VAR(@)\" \
- -c \"link-detect\"; "
-delete:expression: "sudo ip link set $VAR(@) down" ; "Error disabling dev $VAR(@)"
+update: sudo ip link set "$VAR(@)" up
+ vtysh -c "configure terminal" -c "interface $VAR(@)" -c "link-detect"
+delete: sudo ip link set "$VAR(@)" down
allowed: for dev in /sys/class/net/*;
do if [[ -d $dev && -L $dev/device ]]
then if [[ $(cat $dev/type) -eq 1 ]]
diff --git a/templates/interfaces/ethernet/node.tag/vif/node.def b/templates/interfaces/ethernet/node.tag/vif/node.def
index e38b6b2..f0317ce 100644
--- a/templates/interfaces/ethernet/node.tag/vif/node.def
+++ b/templates/interfaces/ethernet/node.tag/vif/node.def
@@ -2,12 +2,10 @@ tag:
type: u32
help: Set Virtual Local Area Network (VLAN) ID
syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 4094; "VLAN ID must be between 0 and 4094"
-create:expression: "sudo modprobe 8021q"; "Error loading 802.1q driver"
-create:expression: "sudo vconfig add $VAR(../@) $VAR(@)"; "Error adding VLAN id $VAR(@) to dev $VAR(../@)"
-create:expression: "sudo ip link set $VAR(../@).$VAR(@) up"; "Error enabling VLAN id $VAR(@) on dev $VAR(../@)"
-create:expression: "vyatta-vtysh -c \"configure terminal\"\
- -c \"interface $VAR(../@).$VAR(@)\" \
- -c \"link-detect\"; "
-delete:expression: "sudo vconfig rem $VAR(../@).$VAR(@)"; "Error removing VLAN id $VAR(@) from dev $VAR(../@)"
+create: sudo modprobe 8021q
+ sudo vconfig add "$VAR(../@)" "$VAR(@)"
+ sudo ip link set "$VAR(../@).$VAR(@)" up
+ vtysh -c "configure terminal" -c "interface $VAR(../@).$VAR(@)" -c "link-detect"
+delete: sudo vconfig rem "$VAR(../@).$VAR(@)"
comp_help: possible completions:
<0-4094> Set VLAN ID