diff --git a/session1/content/lib/cmd_build.sh b/session1/content/lib/cmd_build.sh index 6f046e8..33c9085 100644 --- a/session1/content/lib/cmd_build.sh +++ b/session1/content/lib/cmd_build.sh @@ -116,6 +116,20 @@ _start_lab() { backend_launch "$name" run || { fail "$name did not start"; return 1; } fi done + + # Return only once every guest answers: running `doctor` the instant `up` + # printed its last line used to report false failures during boot. + step "wait for the guests" + local notready=0 + for name in "${VM_NAMES[@]}"; do + if backend_ready "$name" 300; then + ok "$(printf '%-6s ready' "$name")" + else + warn "$name did not answer in time" + notready=1 + fi + done + return $(( notready )) } cmd_up() {