Overclock.net - An Overclocking Community

Overclock.net - An Overclocking Community (https://www.overclock.net/forum/)
-   Coding and Programming (https://www.overclock.net/forum/142-coding-programming/)
-   -   Bash script waiting for input (https://www.overclock.net/forum/142-coding-programming/1605417-bash-script-waiting-input.html)

TLCH723 07-09-2016 08:14 PM

Hi, I have couple places I need to ssh into twice that usually go something like this.
Code:
ssh [email protected]
Enter password
Use Yubikey
ssh [email protected]

address2 can be different depend on the server I want to ssh into.
So I was thinking I write a bash script for each of the server but I am not sure if I can use it since I will need to enter password and yubikey.

Thank you.

tom.slick 07-10-2016 03:16 PM

The login should be done with ssh key-pairs, but you can also use "except"
http://stackoverflow.com/questions/13298487/bash-script-to-ssh-into-a-machine-without-prompting-password-and-without-using-k
http://stackoverflow.com/questions/16928004/how-to-enter-ssh-password-using-bash


All times are GMT -7. The time now is 06:02 PM.

Powered by vBulletin® Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.

User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.
vBulletin Security provided by vBSecurity (Pro) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.

vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.