diff options
author | Michael Walle <michael@walle.cc> | 2016-11-07 17:05:12 +0100 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2016-11-07 22:58:04 +0100 |
commit | a4cbf58f836c8e46f8cdbc9e1eabe1d0b606ce6a (patch) | |
tree | 6f8e461f2e5de28e9c0e90b9c2892e332bacc67d | |
parent | 100ed2c05a47b239b383a2f83f1ffc8bb70b86f9 (diff) | |
download | buildroot-a4cbf58f836c8e46f8cdbc9e1eabe1d0b606ce6a.tar.gz buildroot-a4cbf58f836c8e46f8cdbc9e1eabe1d0b606ce6a.zip |
busybox: allow the user to set the telnetd options
Source /etc/default/telnet to make it possible to override the telnetd
arguments. For example a user may want to set an alternative port.
Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-rwxr-xr-x | package/busybox/S50telnet | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/package/busybox/S50telnet b/package/busybox/S50telnet index 47e2b63e19..82952b8cb8 100755 --- a/package/busybox/S50telnet +++ b/package/busybox/S50telnet @@ -3,10 +3,13 @@ # Start telnet.... # +TELNETD_ARGS=-F +[ -r /etc/default/telnet ] && . /etc/default/telnet + start() { printf "Starting telnetd: " start-stop-daemon -S -q -m -b -p /var/run/telnetd.pid \ - -x /usr/sbin/telnetd -- -F + -x /usr/sbin/telnetd -- $TELNETD_ARGS [ $? = 0 ] && echo "OK" || echo "FAIL" } |