SSH自动登录脚本
作者:互联网
原创转载请注明出处:https://www.cnblogs.com/agilestyle/p/11926792.html
vi app-stg.sh
1 #!/usr/bin/expect -f 2 #auto ssh login 3 set timeout 30 4 spawn ssh hatianqi@181.171.161.10 5 expect "password:" 6 send "12345678\r" 7 interact
wq后
1 chmod 744 app-stg.sh
cd到脚本所在的目录,登录
1 ./app-stg.sh
标签:脚本,stg,登录,app,sh,SSH,ssh,expect 来源: https://www.cnblogs.com/agilestyle/p/11926792.html