I want ssh to forward the SIGTERM signal to the remote command.
ssh root@localhost /root/print-signal.py
Get PID of ssh:
ps aux| grep print-signal
Kill the matching ssh process:
kill pid-of-ssh
Unfortunately only the ssh process itself gets the signal, not the remote command (print-signal.py
). The remote command does not terminate :-(
How can I make ssh "forward" the SIGTERM signal to the remote command?