summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2019-08-19 23:43:29 +0200
committerChristian Poessinger <christian@poessinger.com>2019-08-19 23:43:29 +0200
commitb48e0492833544be14154c8c177bc7ac5551a561 (patch)
treedec781ffe34d21ce62f6ed50a4315301b1f423ff
parent28be52b8965b87f98395ec21aea6c042c6bf7fd8 (diff)
downloadvyatta-cfg-system-b48e0492833544be14154c8c177bc7ac5551a561.tar.gz
vyatta-cfg-system-b48e0492833544be14154c8c177bc7ac5551a561.zip
dummy: T1580: rewrite in new style XML/Python
-rw-r--r--templates/interfaces/dummy/node.def15
-rw-r--r--templates/interfaces/dummy/node.tag/address/node.def12
-rw-r--r--templates/interfaces/dummy/node.tag/description/node.def8
-rw-r--r--templates/interfaces/dummy/node.tag/disable/node.def4
4 files changed, 0 insertions, 39 deletions
diff --git a/templates/interfaces/dummy/node.def b/templates/interfaces/dummy/node.def
deleted file mode 100644
index 1908f9d8..00000000
--- a/templates/interfaces/dummy/node.def
+++ /dev/null
@@ -1,15 +0,0 @@
-tag:
-priority: 300
-type: txt
-help: Dummy interface name
-syntax:expression: pattern $VAR(@) "^dum[0-9]+$" \
- ; "name must be (dum0-dum999)"
-val_help: <dumN>; Dummy interface name
-
-begin: [ -d /sys/module/dummy ] || sudo modprobe dummy
-
-create: sudo ip link add name $VAR(@) type dummy
- sudo ip link set $VAR(@) up
-
-delete: sudo ip link set dev $VAR(@) down
- sudo ip link delete dev $VAR(@)
diff --git a/templates/interfaces/dummy/node.tag/address/node.def b/templates/interfaces/dummy/node.tag/address/node.def
deleted file mode 100644
index 04612379..00000000
--- a/templates/interfaces/dummy/node.tag/address/node.def
+++ /dev/null
@@ -1,12 +0,0 @@
-multi:
-type: ipv4net,ipv6net
-val_help: ipv4net; IPv4 address and prefix length
-val_help: ipv6net; IPv6 address and prefix length
-help: IP address
-
-syntax:expression: exec "/opt/vyatta/sbin/valid_address $VAR(@)"
-
-create: sudo /opt/vyatta/sbin/vyatta-address add $VAR(../@) $VAR(@)
-
-delete: sudo /opt/vyatta/sbin/vyatta-address delete $VAR(../@) $VAR(@)
-
diff --git a/templates/interfaces/dummy/node.tag/description/node.def b/templates/interfaces/dummy/node.tag/description/node.def
deleted file mode 100644
index c6d2789d..00000000
--- a/templates/interfaces/dummy/node.tag/description/node.def
+++ /dev/null
@@ -1,8 +0,0 @@
-type: txt
-help: Description
-
-syntax:expression: pattern $VAR(@) "^.{1,256}$" \
- ; "interface description is too long (limit 256 characters)"
-
-update: sudo sh -c "echo \"$VAR(@)\" >/sys/class/net/$VAR(../@)/ifalias"
-delete: sudo sh -c "echo '' >/sys/class/net/$VAR(../@)/ifalias"
diff --git a/templates/interfaces/dummy/node.tag/disable/node.def b/templates/interfaces/dummy/node.tag/disable/node.def
deleted file mode 100644
index 8c580c95..00000000
--- a/templates/interfaces/dummy/node.tag/disable/node.def
+++ /dev/null
@@ -1,4 +0,0 @@
-help: Disable interface
-update: sudo ip link set $VAR(../@) down
-
-delete: sudo ip link set $VAR(../@) up