proper way to sudo over ssh

I have a script which runs another script via SSH on a remote server using sudo. However, when I type the password, it shows up on the terminal. (Otherwise it works fine)

ssh user@server "sudo script"

What’s the proper way to do this so I can type the password for sudo over SSH without the password appearing as I type?

8 Answers
8

Leave a Comment