I am trying to run the sshpass command inside a bash script, but it does not work.
If I run the same command from the terminal, it works fine, but it does not run in a bash script.
#! /bin/bash
sshpass -p 'password' ssh user@host command
I know the security issues, but now it doesn’t matter.
Can anyone help? Did I miss something.
thanks
source
share