View Single Post
Old 05-17-2024, 07:28 PM   #1317
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 47,216
Karma: 171291588
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
If you look at the NickelMenu doc file, there is a sample command called Telnet (toggle). It looks as if you could modify this to start/stop the FTP server as well.

Code:
#   menu_item :main    :Telnet (toggle)    :cmd_output         :500:quiet :/usr/bin/pkill -f "^/usr/bin/tcpsvd -E 0.0.0.0 2023"
#     chain_success:skip:5
#       chain_failure                      :cmd_spawn          :quiet :/bin/mount -t devpts | /bin/grep -q /dev/pts || { /bin/mkdir -p /dev/pts && /bin/mount -t devpts devpts /dev/pts; }
#       chain_success                      :cmd_spawn          :quiet :exec /usr/bin/tcpsvd -E 0.0.0.0 2023 /usr/sbin/telnetd -i -l /bin/login
#       chain_success                      :dbg_toast          :Started Telnet server on port 2023
#       chain_failure                      :dbg_toast          :Error starting Telnet server on port 2023
#       chain_always:skip:-1
#     chain_success                        :dbg_toast          :Stopped Telnet server on port 2023
DNSB is offline   Reply With Quote