summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Grennan <tgrennan@io.vyatta.com>2007-12-06 11:11:26 -0800
committerTom Grennan <tgrennan@io.vyatta.com>2007-12-06 11:11:26 -0800
commitd9e410568b4d46621b5099ebad75828fc510f734 (patch)
tree0b80be36fc70ffa98edeac1b1f297dc26be8bcea
parentf260a55468cbfef7faf567c5f6b5b6c2bec28008 (diff)
downloadvyatta-op-d9e410568b4d46621b5099ebad75828fc510f734.tar.gz
vyatta-op-d9e410568b4d46621b5099ebad75828fc510f734.zip
fix bug 2521
-rw-r--r--templates/telnet/node.tag/node.def10
-rw-r--r--templates/telnet/node.tag/node.tag/node.def10
2 files changed, 14 insertions, 6 deletions
diff --git a/templates/telnet/node.tag/node.def b/templates/telnet/node.tag/node.def
index 5bcce24..f52266b 100644
--- a/templates/telnet/node.tag/node.def
+++ b/templates/telnet/node.tag/node.def
@@ -1,5 +1,9 @@
help: telnet to <hostname|address>
allowed: vyatta-allowed-hosts
-run: test -x ${vyatta_sbindir}/telnet &&
- ${vyatta_sbindir}/telnet $2 $3 ||
- /usr/bin/telnet $2 $3
+run: if [ -x /usr/bin/telnet ] ; then
+ /usr/bin/$*
+ elif [ -x /bin/busybox ] ; then
+ /bin/busybox $*
+ else
+ echo telnet not found
+ fi
diff --git a/templates/telnet/node.tag/node.tag/node.def b/templates/telnet/node.tag/node.tag/node.def
index 4e0c65e..95bffe8 100644
--- a/templates/telnet/node.tag/node.tag/node.def
+++ b/templates/telnet/node.tag/node.tag/node.def
@@ -1,5 +1,9 @@
help: telnet to <hostname|address> <port|service>
allowed: echo -n '<PORT>'
-run: test -x ${vyatta_sbindir}/telnet &&
- ${vyatta_sbindir}/telnet $2 $3 ||
- /usr/bin/telnet $2 $3
+run: if [ -x /usr/bin/telnet ] ; then
+ /usr/bin/$*
+ elif [ -x /bin/busybox ] ; then
+ /bin/busybox $*
+ else
+ echo telnet not found
+ fi