ЛР4: повторить восстановление основного стенда после clean-clone

This commit is contained in:
IvanMeln1k
2026-12-04 14:49:32 +03:00
parent 1360fe6843
commit 28708b02c9
+10 -1
View File
@@ -49,7 +49,16 @@ cleanup() {
( (
cd "$root" cd "$root"
unset COMPOSE_PROJECT_NAME LB_PORT IMAGE BASE_URL API_IMAGE unset COMPOSE_PROJECT_NAME LB_PORT IMAGE BASE_URL API_IMAGE
make up >/dev/null 2>&1 && ./scripts/wait-ready.sh >/dev/null 2>&1 || true attempt=0
while [ "$attempt" -lt 3 ]; do
if make up >/dev/null 2>&1 && ./scripts/wait-ready.sh >/dev/null 2>&1; then
echo "main stand restarted after the clean-clone check"
exit 0
fi
attempt=$((attempt + 1))
sleep 3
done
echo "clean-clone-check: could not restart the main stand; run make up manually" >&2
) )
fi fi
exit "$status" exit "$status"