// Powers on the droplet and waits for it to be active func power_on_and_wait(id string, client *digitalocean.Client) error { err := client.PowerOn(id) if err != nil { return err } // Wait for power on _, err = WaitForDropletAttribute( id, "active", []string{"off"}, "status", client) if err != nil { return err } return nil }