summaryrefslogtreecommitdiff
path: root/templates/system
diff options
context:
space:
mode:
authorhagbard <vyosdev@derith.de>2019-02-21 15:58:13 -0800
committerhagbard <vyosdev@derith.de>2019-02-21 15:58:13 -0800
commit575d326eb5dc4e7521533819f8b5c12e9d728a87 (patch)
tree44a3fc4ff180f7405bf8eb09267e3a91d57b6934 /templates/system
parente171516225bad627b70aed808868396d9264a707 (diff)
downloadvyatta-cfg-system-575d326eb5dc4e7521533819f8b5c12e9d728a87.tar.gz
vyatta-cfg-system-575d326eb5dc4e7521533819f8b5c12e9d728a87.zip
Fixes: T1257: implement 'set system static-host-mapping' in host_name.py
Diffstat (limited to 'templates/system')
-rw-r--r--templates/system/static-host-mapping/host-name/node.def21
-rw-r--r--templates/system/static-host-mapping/host-name/node.tag/alias/node.def3
-rw-r--r--templates/system/static-host-mapping/host-name/node.tag/inet/node.def4
-rw-r--r--templates/system/static-host-mapping/node.def2
4 files changed, 0 insertions, 30 deletions
diff --git a/templates/system/static-host-mapping/host-name/node.def b/templates/system/static-host-mapping/host-name/node.def
deleted file mode 100644
index 9d815965..00000000
--- a/templates/system/static-host-mapping/host-name/node.def
+++ /dev/null
@@ -1,21 +0,0 @@
-tag:
-type: txt
-help: Host name for static address mapping
-
-syntax:expression: pattern $VAR(@) "^[[:alnum:]][-.[:alnum:]]*[[:alnum:]]$"
- ; "invalid host name $VAR(@)"
-
-
-commit:expression: $VAR(./inet) != ""; "IP address for the static mapping must be set"
-
-end: sudo sh -c "
- touch /etc/hosts
- sed -i '/ $VAR(@) .*#vyatta entry/d' /etc/hosts
- if [ -z \"$VAR(./inet/@)\" ]; then
- if cli-shell-api existsActive service dns forwarding; then /etc/init.d/pdns-recursor restart >&/dev/null; fi
- exit 0
- fi
- declare -a aliases=( $VAR(alias/@@) )
- echo -e \"$VAR(inet/@)\\t $VAR(@) \${aliases[*]} \\t #vyatta entry\" >> /etc/hosts
- if cli-shell-api existsActive service dns forwarding; then /etc/init.d/pdns-recursor restart >&/dev/null; fi"
-
diff --git a/templates/system/static-host-mapping/host-name/node.tag/alias/node.def b/templates/system/static-host-mapping/host-name/node.tag/alias/node.def
deleted file mode 100644
index 2f340fc7..00000000
--- a/templates/system/static-host-mapping/host-name/node.tag/alias/node.def
+++ /dev/null
@@ -1,3 +0,0 @@
-multi:
-type: txt
-help: Alias for this address
diff --git a/templates/system/static-host-mapping/host-name/node.tag/inet/node.def b/templates/system/static-host-mapping/host-name/node.tag/inet/node.def
deleted file mode 100644
index baae548b..00000000
--- a/templates/system/static-host-mapping/host-name/node.tag/inet/node.def
+++ /dev/null
@@ -1,4 +0,0 @@
-type: ipv4,ipv6
-help: Address [REQUIRED]
-val_help: ipv4; IPv4 address
-val_help: ipv6; IPv6 address
diff --git a/templates/system/static-host-mapping/node.def b/templates/system/static-host-mapping/node.def
deleted file mode 100644
index f1fe94a7..00000000
--- a/templates/system/static-host-mapping/node.def
+++ /dev/null
@@ -1,2 +0,0 @@
-priority: 400
-help: Map host names to addresses