-
Notifications
You must be signed in to change notification settings - Fork 80
test: wait for registration-service route in scripts/ci/manage-devsandbox-dashboard.sh
#1240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -176,6 +176,22 @@ if [[ ${DEPLOY_UI} == "true" ]]; then | |
| # Get the HOST_NS (host operator namespace) | ||
| HOST_NS=$(oc get projects -l app=host-operator --output=name -o jsonpath='{range .items[*]}{.metadata.name}{"\n"}{end}' | sort | tail -n 1) | ||
|
|
||
| # Wait for registration-service deployment and route to be ready | ||
| oc wait --for=condition=Available deployment/registration-service -n ${HOST_NS} --timeout=5m | ||
| # Wait for registration-service route to exist | ||
| NEXT_WAIT_TIME=0 | ||
| while [[ -z $(oc get routes registration-service -n ${HOST_NS} -o jsonpath='{.status.ingress[0].host}' 2>/dev/null || true) ]]; do | ||
| if [[ ${NEXT_WAIT_TIME} -eq 60 ]]; then | ||
| echo "" | ||
| echo "[$(date '+%Y-%m-%d %H:%M:%S')] ERROR: Timeout waiting for registration-service route" | ||
| oc get routes -n ${HOST_NS} | ||
| exit 1 | ||
| fi | ||
| echo -n "." | ||
| sleep 2 | ||
| ((NEXT_WAIT_TIME++)) | ||
| done | ||
|
|
||
|
Comment on lines
+179
to
+194
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add newline after successful route wait. The progress indicator prints dots during the wait (line 190), but when the loop exits successfully, there's no newline or success message. This causes the dots to run into the next output line, making the logs harder to read. 🔎 Apply this diff to improve output formatting: done
+ echo ""
+ echo "[$(date '+%Y-%m-%d %H:%M:%S')] registration-service route is ready"
# Get the Registration Service API URL🤖 Prompt for AI Agents |
||
| # Get the Registration Service API URL | ||
| REGISTRATION_SERVICE_API="https://$(oc get route registration-service -n ${HOST_NS} -o custom-columns=":spec.host" | tr -d '\n')/api/v1" | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.