Skip to content

Commit

Permalink
Cluster.up on ray cluster object
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxusmusti committed Sep 26, 2023
1 parent dc540c1 commit ab9a16a
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions src/codeflare_sdk/cluster/cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,16 @@ def up(self):
with open(self.app_wrapper_yaml) as f:
yamls = yaml.load_all(f, Loader=yaml.FullLoader)
for resource in yamls:
print(resource["kind"])
# api_instance.create_namespaced_custom_object(
# group="ray.io",
# version="v1alpha1",
# namespace=namespace,
# plural="rayclusters",
# body=aw,
# )
if resource["kind"] == "RayCluster":
api_instance.create_namespaced_custom_object(
group="ray.io",
version="v1alpha1",
namespace=namespace,
plural="rayclusters",
body=resource,
)
else:
print(resource["kind"])
except Exception as e: # pragma: no cover
return _kube_api_error_handling(e)

Expand Down

0 comments on commit ab9a16a

Please sign in to comment.