Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions scripts/ci/manage-devsandbox-dashboard.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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 thread
MatousJobanek marked this conversation as resolved.

Comment on lines +179 to +194
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

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
In scripts/ci/manage-devsandbox-dashboard.sh around lines 179 to 194, the
progress dots printed while waiting for the registration-service route do not
end with a newline or success message, causing the dots to run into subsequent
log output; after the waiting loop completes successfully, add a newline (e.g.,
echo "" or printf "\n") and optionally a short success/log message (with
timestamp) so the dots end on their own line and the logs remain readable.

# 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"

Expand Down
Loading