File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
src/codeflare_sdk/cluster Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -691,6 +691,7 @@ def get_cluster(cluster_name: str, namespace: str = "default"):
691
691
config_check ()
692
692
api_instance = client .NetworkingV1Api (api_config_handler ())
693
693
ingresses = api_instance .list_namespaced_ingress (namespace )
694
+ ingress_host = None
694
695
if mcad == True :
695
696
for ingress in ingresses .items :
696
697
# Search for ingress with AppWrapper name as the owner
@@ -705,7 +706,11 @@ def get_cluster(cluster_name: str, namespace: str = "default"):
705
706
return _kube_api_error_handling (e )
706
707
707
708
# We gather the ingress domain from the host
708
- ingress_domain = ingress_host .split ("." , 1 )[1 ]
709
+ if ingress_host is not None :
710
+ ingress_domain = ingress_host .split ("." , 1 )[1 ]
711
+ else :
712
+ ingress_domain = None
713
+
709
714
return Cluster .from_k8_cluster_object (
710
715
rc , mcad = mcad , ingress_domain = ingress_domain
711
716
)
You can’t perform that action at this time.
0 commit comments