die_gracefully("You've specified the remote host, but not the remote login.")
unless defined $c->{'remote'}{'login'};
- $c->{'rmtssh'} = "ssh "
+ $c->{'remote'}{'ssh'} = "ssh "
. (defined $c->{'remote'}{'sshargs'} ? $c->{'remote'}{'sshargs'} . ' ' : '')
. " -l $c->{'remote'}{'login'} $c->{'remote'}{'host'}";
}
sub test {
my ($test) = shift;
- if (defined $c->{rmtssh}) {
- system("$c->{rmtssh} [ $test ]");
+ if (defined $c->{'remote'}{'ssh'}) {
+ system("$c->{'remote'}{'ssh'} [ $test ]");
return ($? >> 8);
} else {
sub run_and_check {
my ($cmd, $die) = shift;
- $cmd = "$c->{$rmtssh} \"$cmd\""
- if defined $c->{rmtssh};
+ $cmd = "$c->{'remote'}{'ssh'} \"$cmd\""
+ if defined $c->{'remote'}{'ssh'};
if (defined $DEBUG) {
print "Want to run: $cmd\n";
sub run_and_return {
my ($cmd, $die) = shift;
- $cmd = "$c->{$rmtssh} \"$cmd\""
- if defined $c->{rmtssh};
+ $cmd = "$c->{'remote'}{'ssh'} \"$cmd\""
+ if defined $c->{'remote'}{'ssh'};
my $output = `$cmd`;
if ($? >> 8 != 0) {