If you already have a working solution with rsh, why not try to adapt it to use ssh? It should require just a bit of tinkering. Don't put passwords in code. Maybe set up the script runner to have an .ssh config to allow it to do what it needs to do (and nothing else).
| [reply] |
I've tried that, but when I shutdown the application the ssh thread remains and I have to kill it manually. Is there a way to make sure the thread is cleaned up?
| [reply] |
Yes. You can keep track of the pids of the ssh runs. I, however, am not the right monk to throw down an example of how to do that.
Try to distill it down to a snippet that runs something you're doing and post it as a new SoPW asking how to keep track of and kill/close the ssh when you're done with it.
| [reply] |