I have successfully configured ssh, I can login to my remote Linux server without being prompted for a password, however when I try an add this into a script I get prompted for a password...
What Im trying to do is is to login remotely using ssh then run a command using the root user:
From my Linux server I run
sudo -u my_ssh_account ssh firstname.lastname@example.org
sudo - root /tmp/mycommand
This works, but when I put it into a script it prompts me to enter the ssh accounts password...and Im puzzled
Any thoughts suggestions would be apreciated .