avonnieda has asked for the wisdom of the Perl Monks concerning the following question:
$ssh = Net::OpenSSH->new($hostname, user => $username, master_stderr_discard => 1}
$command = "cd /usr/local/bin; /bin/echo -e \"input1\ninput2\ninput3\" | interactive_program.pl";
@out = $ssh->capture($command);
Thanks!
-Adam vonNieda
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to execute Net::OpenSSH remote command requiring input
by salva (Canon) on Oct 26, 2009 at 15:13 UTC | |
by avonnieda (Novice) on Oct 26, 2009 at 15:55 UTC | |
|
Re: How to execute Net::OpenSSH remote command requiring input
by avonnieda (Novice) on Oct 26, 2009 at 15:00 UTC |