builder/digitalocean: break loop if we reach off state
Otherwise we get stuck in a long loop. Whoops.
This commit is contained in:
parent
82b46816d3
commit
39f7a5a617
|
@ -32,6 +32,10 @@ func (s *stepPowerOff) Run(state multistep.StateBag) multistep.StepAction {
|
|||
}
|
||||
|
||||
err = waitForDropletState("off", dropletId, client, 20*time.Second)
|
||||
if err == nil {
|
||||
// We reached the state!
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in New Issue