simpler, more robust PBS promise
removed call to ssh.terminate()