def _wait_for_status(self, cond, retries=10):
        while retries >= 0:
            status = self.container.status(refresh=True)
            if cond(status):
                return True
            retries -= 1
            if retries >= 0:
                time.sleep(0.5)
        return False
Wait for the container's status to comply to the given condition.
dataset/ETHPy150Open signalfx/maestro-ng/maestro/plays/tasks.py/Task._wait_for_status