Skip to content

Commit eb92343

Browse files
Add label to RayCluster if owned by AppWrapper
1 parent 003a287 commit eb92343

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/codeflare_sdk/ray/cluster/build_ray_cluster.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ def build_ray_cluster(cluster: "codeflare_sdk.ray.cluster.Cluster"):
182182
# Metadata related functions
183183
def get_metadata(cluster: "codeflare_sdk.ray.cluster.Cluster"):
184184
"""
185-
The get_metadata() function builds and returns a V1ObjectMeta Object using cluster configurtation parameters
185+
The get_metadata() function builds and returns a V1ObjectMeta Object using cluster configuration parameters
186186
"""
187187
object_meta = V1ObjectMeta(
188188
name=cluster.config.name,
@@ -207,6 +207,9 @@ def get_labels(cluster: "codeflare_sdk.ray.cluster.Cluster"):
207207
if cluster.config.labels != {}:
208208
labels.update(cluster.config.labels)
209209

210+
if cluster.config.appwrapper is True:
211+
labels.update({"resource.owner": "appwrapper"})
212+
210213
if cluster.config.appwrapper is False:
211214
add_queue_label(cluster, labels)
212215

0 commit comments

Comments
 (0)