Skip to content

Commit 4780b0b

Browse files
committed
More debugging
1 parent ed5ae36 commit 4780b0b

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

integration-tests/pipelines/rhtap-cli-e2e_hive.yaml

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,40 @@ spec:
177177
# --- Console URL Accessibility Check ---
178178
echo "--- Starting Console Accessibility Check ---"
179179
180-
console_url="https://$(oc get route console -n openshift-console -o jsonpath='{.spec.host}')"
180+
181+
oc whoami
182+
oc whoami --show-console
183+
# Check if routes are available (OpenShift-specific resource)
184+
echo "Checking if routes are available..."
185+
if ! oc api-resources | grep -q "routes"; then
186+
echo "Warning: Routes are not available. This might not be an OpenShift cluster or it's not fully ready."
187+
echo "Waiting for OpenShift components to be ready..."
188+
sleep 30
189+
if ! oc api-resources | grep -q "routes"; then
190+
echo "Error: Routes still not available. This doesn't appear to be an OpenShift cluster."
191+
exit 1
192+
fi
193+
fi
194+
195+
# Check if openshift-console namespace exists
196+
echo "Checking if openshift-console namespace exists..."
197+
if ! oc get namespace openshift-console &>/dev/null; then
198+
echo "Error: openshift-console namespace not found."
199+
exit 1
200+
fi
201+
202+
# Wait for console route to be available
203+
echo "Waiting for console route to be available..."
204+
for ((k=1; k<=10; k++)); do
205+
if oc get route console -n openshift-console &>/dev/null; then
206+
echo "Console route found."
207+
break
208+
fi
209+
echo "Console route not found, attempt $k/10. Waiting 30 seconds..."
210+
sleep 30
211+
done
212+
213+
console_url="https://$(oc get route console -n openshift-console -o jsonpath='{.spec.host}' 2>/dev/null)"
181214
182215
if [[ -z "$console_url" ]]; then
183216
echo "Error: Could not retrieve OpenShift console URL."

0 commit comments

Comments
 (0)