5555          APP_HOST=$(kubectl get svc ${{ inputs.app_name }}-svc -n ${{ inputs.app_namespace }} -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' 2>/dev/null || echo 'Not found') 
5656
5757          # Monitoring ingress information 
58-           MONITORING_DOMAIN=$(kubectl get ingress -n ${{ inputs.monitoring_namespace }} -o jsonpath='{.items[0].spec.rules[0].host}' 2>/dev/null || echo 'Not found') 
59-           INGRESS_IP=$(kubectl get ingress -n ${{ inputs.monitoring_namespace }} -o jsonpath='{.items[0].status.loadBalancer.ingress[0].ip}' 2>/dev/null || echo '') 
60-           INGRESS_HOSTNAME=$(kubectl get ingress -n ${{ inputs.monitoring_namespace }} -o jsonpath='{.items[0].status.loadBalancer.ingress[0].hostname}' 2>/dev/null || echo '') 
58+           NGINX_HOSTNAME=$(kubectl get svc -n ingress-nginx ingress-nginx-controller -o jsonpath='{.status.loadBalancer.ingress[0].hostname}') 
6159
6260          # NGINX ingress controller LoadBalancer 
6361          NGINX_LB=$(kubectl get svc -n ingress-nginx ingress-nginx-controller -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' 2>/dev/null || echo 'Not found') 
@@ -67,48 +65,23 @@ jobs:
6765          echo "🌟 App: http://$APP_HOST" 
6866          echo "" 
6967          echo "📊 Monitoring Services (via Ingress):" 
70-           if [ "$MONITORING_DOMAIN" != "Not found" ]; then 
71-             echo "   Domain: $MONITORING_DOMAIN" 
72-             echo "   📊 Prometheus: http://$MONITORING_DOMAIN/prometheus" 
73-             echo "   📈 Grafana: http://$MONITORING_DOMAIN/grafana" 
74-             echo "   🚨 Alertmanager: http://$MONITORING_DOMAIN/alertmanager" 
75-             echo "" 
76-             echo "   Ingress Status:" 
77-             [ ! -z "$INGRESS_IP" ] && echo "   IP: $INGRESS_IP" 
78-             [ ! -z "$INGRESS_HOSTNAME" ] && echo "   LoadBalancer: $INGRESS_HOSTNAME" 
79-           else 
80-             echo "   ⚠️  Ingress not found or not ready" 
68+           if [ "$NGINX_HOSTNAME" != "Not found" ]; then 
69+             echo "   Domain: $NGINX_HOSTNAME" 
70+             echo "   📊 Prometheus: http://$NGINX_HOSTNAME/prometheus" 
71+             echo "   📈 Grafana: http://$NGINX_HOSTNAME/grafana" 
72+             echo "   🚨 Alertmanager: http://$NGINX_HOSTNAME/alertmanager" 
8173          fi 
82- 
8374          echo "" 
8475          echo "🌐 NGINX Ingress Controller: $NGINX_LB" 
8576
86-           echo "" 
87-           echo "================= DETAILED INGRESS STATUS =================" 
88-           echo "All Ingress Resources:" 
89-           kubectl get ingress -A -o wide 2>/dev/null || echo "No ingress resources found" 
90-           echo "" 
91-           echo "Monitoring Namespace Ingress Details:" 
92-           kubectl describe ingress -n ${{ inputs.monitoring_namespace }} 2>/dev/null || echo "No ingress in monitoring namespace" 
93- 
94-           echo "" 
95-           echo "================= SERVICE STATUS =================" 
96-           echo "Monitoring Services (should be ClusterIP):" 
97-           kubectl get svc -n ${{ inputs.monitoring_namespace }} -l app.kubernetes.io/instance=kube-prometheus-stack 2>/dev/null || echo "No monitoring services found" 
98- 
99-           echo "" 
100-           echo "All LoadBalancer Services:" 
101-           kubectl get svc -A --field-selector spec.type=LoadBalancer -o wide 2>/dev/null || echo "No LoadBalancer services found" 
102- 
103-           echo "" 
104-           echo "NGINX Ingress Controller Status:" 
105-           kubectl get svc -n ingress-nginx -o wide 2>/dev/null || echo "NGINX Ingress Controller not found" 
106- 
10777          echo "" 
10878          echo "================= DEFAULT CREDENTIALS =================" 
10979          ARGOCD_PASS=$(kubectl -n ${{ inputs.argocd_namespace }} get secret argocd-initial-admin-secret -o jsonpath='{.data.password}' 2>/dev/null | base64 -d || echo 'Not found') 
11080          echo "ArgoCD -> Username: admin" 
11181          echo "ArgoCD -> Password: $ARGOCD_PASS" 
11282          echo "Grafana -> Username: admin" 
113-           echo "Grafana -> Password: ${{ secrets.GRAFANA_PASSWORD }}" 
114-           echo "Prometheus -> No login needed (anonymous access by default)" 
83+           echo "Grafana -> Password: (stored in GitHub Secrets, not printed)" 
84+           echo "Prometheus -> No login needed (anonymous access by default)" 
85+           echo "Alertmanager -> No login needed (anonymous access by default)" 
86+           echo "" 
87+           echo "⚠️  Note: It may take a few minutes for LoadBalancer endpoints to become fully available after deployment." 
0 commit comments