Execute Command SSH

Post Reply
matthew.hearne
Newbie
Posts: 4
Joined: Thu Dec 19, 2019 3:00 pm

Execute Command SSH

Post by matthew.hearne » Tue Oct 13, 2020 3:48 pm

We'd like to be able to have a flow where we can run a command(s) on a remote machine using SSH.

The machine we want to connect to is accepting SSH connections as we have tested this from the machine running Switch (a Mac using Terminal) to the remote machine (a Windows 10 pc).

We are guessing that we'd be able to use Execute Command to do this, but unsure as to how you would execute multiple commands in sequence i.e. login to the remote machine, run a command, then log off the machine.

Any help or ideas on how to do this would be appreciated.

freddyp
Advanced member
Posts: 530
Joined: Thu Feb 09, 2012 3:53 pm

Re: Execute Command SSH

Post by freddyp » Tue Oct 13, 2020 6:07 pm

You should let the property "Command or path" of "Execute command" point to a shell script instead of to ssh itself. Do not forget to chmod +x the shell script!

jan_suhr
Advanced member
Posts: 362
Joined: Fri Nov 04, 2011 1:12 pm
Location: Nyköping, Sweden

Re: Execute Command SSH

Post by jan_suhr » Tue Oct 13, 2020 6:14 pm

And to create a shell script on the fly with variables you can use the app Execute Command Friend.
Jan Suhr
Color Consult AB
Sweden
=============
Check out my apps

matthew.hearne
Newbie
Posts: 4
Joined: Thu Dec 19, 2019 3:00 pm

Re: Execute Command SSH

Post by matthew.hearne » Tue Oct 13, 2020 6:17 pm

Hi. Thanks for the replies. Will have a look into this in the next few days.

Appreciate the help with this one.

Post Reply