Last active
July 6, 2017 03:23
-
-
Save mikedamoiseau/c4a7b92cf831b32fbe4a5a0f0e878c5c to your computer and use it in GitHub Desktop.
Alias to ssh with password
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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