Custom PowerShell Script calling SSH

I have a step in my process where I want ot call an ssh target (this is to remove a server from a load balancer prior to deploying to it).

The TARGET is windows (not SSH), the tentacle is a regular windows listener tentacle, however on that tentacle, i’m running Open SSH to run a script on a linux server. It runs fine when executing the powershell script directly from the machine, but when I try to run that same power shell script from Octopus, it hangs at the SSH and doesn’t proceed.

The SSH command does not prompt for a login or any any other inputs.

Thanks for your assistance

Hi Christian,

Thanks for reaching out. The SSH command could be hanging due to the SSH known hosts prompt. If you are running the Tentacle service under the “Local System” account it will be using its own SSH profile different to the local user you are testing the script with.
You could try running the ssh command with the option -o StrictHostKeyChecking=no
e.g ssh -o StrictHostKeyChecking=no user@hostname

I hope that helps, please let me know if you have any further questions.

Kind Regards,
Tom W

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.