This is not really a SAS problem, but hey...
Generally, executing a remote command using SSH goes like:
ssh userid@remotehost "your command".
In your case it would involve having the entire script executed remotely. Your command would be ExportPackage and its parameters or perhaps the entire script.
You can add options to ssh to avoid chatter that cannot be handled when running non-interactively. Most noteworthy are '-PasswordAuthentication no', 'StrictHostKeyChecking no' and 'LogLevel quiet'. Also you must have your public key shared between the hosts so you can use ssh passwordless.
And keep in mind that the resulting package and log files will be created remotely as well. So unless you have a shared filesystem you will have to scp them back to the calling host as a next step.
Do keep in mind that this command does not need to be executed on the metadata server. It can be done from any machine that has SAS installed at or least the SASPlatformObjectFramework installed and an unhindered network connection to the metadata server.
Hope this helps,
-- Jan.