in reply to Re: Send password in Net::SSH::Expect
in thread Send password in Net::SSH::Expect
The idea here is to replace the entry in /tmp/test.txt containing the $hostname with the $skey string. It works from the shell itself, but fails from the script, so I am pretty sure it is a escape issue.system("ssh -q $ssh_user\@$bkp_destination 'sed -i \"s#.*$hostname#$sk +ey#g\" /tmp/test.txt'");
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Send password in Net::SSH::Expect
by gafaman (Novice) on Jan 23, 2020 at 08:51 UTC | |
by Corion (Patriarch) on Jan 23, 2020 at 09:03 UTC | |
by gafaman (Novice) on Jan 23, 2020 at 09:24 UTC | |
by Corion (Patriarch) on Jan 23, 2020 at 09:36 UTC | |
by gafaman (Novice) on Jan 23, 2020 at 09:58 UTC | |
|