fix for SF defect 3412

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@15765 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
lissav 2013-04-01 15:57:14 +00:00
parent eacf7bb705
commit 6a11d0230f

View File

@ -656,16 +656,15 @@ sub makescript
}
# get postscripts for images
my $osimgname = $provmethod;
my $et2;
if($provmethod !~ /^install$|^netboot$|^statelite$/){ # using imagename
my $osimgname = $provmethod;
if($osimgname =~ /install|netboot|statelite/){
$osimgname = "$os-$arch-$provmethod-$profile";
}
my $et2 =
$et2 =
$ostab->getAttribs({'imagename' => "$osimgname"}, ['postscripts', 'postbootscripts']);
$ps = $et2->{'postscripts'};
if ($ps)
{
$ps = $et2->{'postscripts'};
if ($ps)
{
foreach my $n (split(/,/, $ps))
{
if (!exists($post_hash{$n}))
@ -674,6 +673,7 @@ sub makescript
push @scriptd, $n . "\n";
}
}
}
}
# get postscripts for node specific
@ -724,9 +724,10 @@ sub makescript
}
# get postbootscripts for image
my $ips = $et2->{'postbootscripts'};
if ($ips)
{
if($provmethod !~ /^install$|^netboot$|^statelite$/){ # using imagename
my $ips = $et2->{'postbootscripts'};
if ($ips)
{
foreach my $n (split(/,/, $ips))
{
if (!exists($postboot_hash{$n}))
@ -735,6 +736,7 @@ sub makescript
push @scriptd, $n . "\n";
}
}
}
}