
The remrun tool may be useful for one-off execution of a series of commands or a complicated command that does not easily lend itself to shell quoting and escaping via SSH. It copies the specified file to the remote host using SSH under a temporary filename, executes it on the remote side, then removes the temporary file.