From 5b81a7a8cad4e3416c0bec2f874018884c8a81bf Mon Sep 17 00:00:00 2001 From: daniceexi Date: Tue, 14 May 2013 02:41:23 +0000 Subject: [PATCH] add comment to support multiple actions for the nodeset state git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16283 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/destiny.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xCAT-server/lib/xcat/plugins/destiny.pm b/xCAT-server/lib/xcat/plugins/destiny.pm index b9ed5f810..06c861997 100644 --- a/xCAT-server/lib/xcat/plugins/destiny.pm +++ b/xCAT-server/lib/xcat/plugins/destiny.pm @@ -91,6 +91,8 @@ sub setdestiny { my @nodes=@{$req->{node}}; my $state = $req->{arg}->[0]; my $reststates; + + # to support the case that the state could be runimage=xxx,runimage=yyy,osimage=xxx ($state, $reststates) = split (/,/, $state, 2); my %nstates; my %fstates; @@ -464,6 +466,8 @@ sub setdestiny { $lstate = $nstates{$_}; } $chaintab->setNodeAttribs($_,{currstate=>$lstate}); + # if there are multiple actions in the state argument, set the rest of states (shift out the first one) + # to chain.currchain so that the rest ones could be used by nextdestiny command if ($reststates) { $chaintab->setNodeAttribs($_,{currchain=>$reststates}); }