diff --git a/test/infrastructure/docker/exp/docker/nodepool.go b/test/infrastructure/docker/exp/docker/nodepool.go index cdf68a76b47b..eaa55aec00e7 100644 --- a/test/infrastructure/docker/exp/docker/nodepool.go +++ b/test/infrastructure/docker/exp/docker/nodepool.go @@ -249,6 +249,14 @@ func (np *NodePool) reconcileMachine(ctx context.Context, machine *docker.Machin if err := externalMachine.ExecBootstrap(timeoutctx, bootstrapData); err != nil { return ctrl.Result{}, errors.Wrapf(err, "failed to exec DockerMachinePool instance bootstrap for instance named %s", machine.Name()) } + + timeoutctx, cancel = context.WithTimeout(ctx, 1*time.Minute) + defer cancel() + // Check for bootstrap success + if err := externalMachine.CheckForBootstrapSuccess(timeoutctx); err != nil { + return ctrl.Result{}, errors.Wrap(err, "failed to check for existence of bootstrap success file at /run/cluster-api/bootstrap-success.complete") + } + machineStatus.Bootstrapped = true // return to surface the machine has been bootstrapped. return ctrl.Result{Requeue: true}, nil