Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Alias to ssh with password
1. Install sshpass `sudo apt-get update && sudo apt-get install sshpass`
2. edit file `~/.bash_aliases`
3. add the line `alias name_of_alias='sshpass -f <(printf "%s\n" "our_password") ssh user@hostname'
4. compile your `.bash_aliases` file: `source .bash_aliases``
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment