Skip to content

Commit 9727f9a

Browse files
authored
Fixed ingress domain methods (#263)
1 parent 97bf513 commit 9727f9a

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/codeflare_sdk/cluster/cluster.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ def get_cluster(cluster_name: str, namespace: str = "default"):
429429
def _get_ingress_domain():
430430
try:
431431
config.load_kube_config()
432-
api_client = client.CustomObjectsApi()
432+
api_client = client.CustomObjectsApi(api_config_handler())
433433
ingress = api_client.get_cluster_custom_object(
434434
"config.openshift.io", "v1", "ingresses", "cluster"
435435
)

src/codeflare_sdk/utils/generate_yaml.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import uuid
2424
from kubernetes import client, config
2525
from .kube_api_helpers import _kube_api_error_handling
26+
from ..cluster.auth import api_config_handler
2627

2728

2829
def read_template(template):
@@ -251,7 +252,7 @@ def enable_local_interactive(resources, cluster_name, namespace):
251252
command = command.replace("deployment-name", cluster_name)
252253
try:
253254
config.load_kube_config()
254-
api_client = client.CustomObjectsApi()
255+
api_client = client.CustomObjectsApi(api_config_handler())
255256
ingress = api_client.get_cluster_custom_object(
256257
"config.openshift.io", "v1", "ingresses", "cluster"
257258
)

0 commit comments

Comments
 (0)