fixed bug 3718. This fix only checked into xCAT 2.9

This commit is contained in:
jjhua 2013-08-13 17:13:47 -04:00
parent fcd5f2fc45
commit 1d3d316d05
3 changed files with 5 additions and 3 deletions

View File

@ -186,15 +186,15 @@ sub makescript {
if($entries[0]) {
$installroot = $entries[0];
}
my $tmpl="$installroot/postscripts/mypostscript.tmpl";
my $tmpl="$installroot/postscripts/mypostscript.tmpl"; #the customized mypostscript template
unless ( -r $tmpl) {
$tmpl="$::XCATROOT/share/xcat/templates/mypostscript/mypostscript.tmpl";
$tmpl="$::XCATROOT/share/xcat/mypostscript/mypostscript.tmpl"; #the default xcat mypostscript template
}
unless ( -r "$tmpl") {
my $rsp;
$rsp->{data}->[0]= "No mypostscript template exists in directory /install/postscripts or $::XCATROOT/share/xcat/templates/mypostscript/mypostscript.tmpl.\n";
$rsp->{data}->[0]= "No mypostscript template exists in directory /install/postscripts or $::XCATROOT/share/xcat/mypostscript/mypostscript.tmpl.\n";
xCAT::MsgUtils->message("SE", $rsp, $callback,1);
return ;
}

View File

@ -72,6 +72,7 @@ mkdir -p $RPM_BUILD_ROOT/%{prefix}/bin
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/install
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/netboot
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/ca
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/mypostscript
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/scripts
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/samples
mkdir -p $RPM_BUILD_ROOT/%{prefix}/share/xcat/tools
@ -118,6 +119,7 @@ chmod -h 755 $RPM_BUILD_ROOT/%{prefix}/bin/*
cp share/xcat/ca/* $RPM_BUILD_ROOT/%{prefix}/share/xcat/ca
chmod 644 $RPM_BUILD_ROOT/%{prefix}/share/xcat/ca/*
cp share/xcat/mypostscript/* $RPM_BUILD_ROOT/%{prefix}/share/xcat/mypostscript
cp share/xcat/scripts/* $RPM_BUILD_ROOT/%{prefix}/share/xcat/scripts
cp share/xcat/samples/* $RPM_BUILD_ROOT/%{prefix}/share/xcat/samples
cp -r share/xcat/tools/* $RPM_BUILD_ROOT/%{prefix}/share/xcat/tools