blob: 5976addda1a6d5e9435ae598d76fd0019c2346ce (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
help: Enable/disable Network Virtual Terminal Protocol (TELNET) protocol
delete:expression: " \
if ! env | grep -q SSH_TTY=; then \
if [[ \"`tty`\" == /dev/pts/* ]]; then \
echo \"Please configure telnet settings via ssh or console.\"; \
exit 1; \
fi; \
fi; \
sudo /opt/vyatta/sbin/telnetd.init stop"
end:expression: " \
if ! env | grep -q SSH_TTY=; then \
if [[ \"`tty`\" == /dev/pts/* ]]; then \
echo \"Please configure telnet settings via ssh or console.\"; \
exit 1; \
fi; \
fi; \
if [ -z \"$VAR(port/@)\" ]; then exit 0; fi; \
sudo /opt/vyatta/sbin/telnetd.init restart $VAR(port/@)"
|