From 4216f490a14328b99d309b86f1c643410e7140ea Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Thu, 29 Aug 2019 14:57:44 +0200 Subject: T1598: delete the old static-host-mapping CLI. --- .../system/static-host-mapping/host-name/node.def | 21 --------------------- .../host-name/node.tag/alias/node.def | 3 --- .../host-name/node.tag/inet/node.def | 4 ---- templates/system/static-host-mapping/node.def | 2 -- 4 files changed, 30 deletions(-) delete mode 100644 templates/system/static-host-mapping/host-name/node.def delete mode 100644 templates/system/static-host-mapping/host-name/node.tag/alias/node.def delete mode 100644 templates/system/static-host-mapping/host-name/node.tag/inet/node.def delete mode 100644 templates/system/static-host-mapping/node.def 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 -- cgit v1.2.3