relative path support for xdcp

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5158 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
ligc 2010-02-05 03:16:04 +00:00
parent b3332a63e0
commit 32e47721d6

View File

@ -96,9 +96,13 @@ else
}
}
foreach (@SaveARGV)
foreach my $sarg (@SaveARGV)
{
push(@{$cmdref->{arg}}, $_);
if (($bname eq "xdcp") && ( $sarg !~ /^\//))
{
$sarg = xCAT::Utils->full_path($sarg);
}
push(@{$cmdref->{arg}}, $sarg);
}
# add environment variables, if they have not already been assigned with
@ -499,6 +503,12 @@ sub parse_args_xdcp
xCAT::DSHCLI->show_dsh_config;
exit 0;
}
if ( exists( $options{File} ) && ($options{File} !~ /^\//) ) {#relative path
$options{File} = xCAT::Utils->full_path($options{File});
}
if ( exists( $options{rootimg} ) && ($options{rootimg} !~ /^\//) ) {#relative path
$options{rootimg} = xCAT::Utils->full_path($options{rootimg});
}
# rsync only to the service node
if ($options{'rsyncSN'})