Skip to content

Commit 0e83c6d

Browse files
committed
remove ray shutdown and init calls from local test
Signed-off-by: Saad Zaher <[email protected]>
1 parent d109bb7 commit 0e83c6d

File tree

3 files changed

+290
-2
lines changed

3 files changed

+290
-2
lines changed

tests/e2e/local_interactive_sdk_kind_test.py

-2
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,6 @@ def run_local_interactives(
6565

6666
print(cluster.local_client_url())
6767

68-
ray.shutdown()
69-
ray.init(address=cluster.local_client_url(), logging_level="DEBUG")
7068

7169
@ray.remote(num_gpus=number_of_gpus / 2)
7270
def heavy_calculation_part(num_iterations):
+145
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,145 @@
1+
apiVersion: ray.io/v1
2+
kind: RayCluster
3+
metadata:
4+
labels:
5+
controller-tools.k8s.io: '1.0'
6+
name: default-cluster
7+
namespace: ns
8+
spec:
9+
autoscalerOptions:
10+
idleTimeoutSeconds: 60
11+
resources:
12+
limits:
13+
cpu: 500m
14+
memory: 512Mi
15+
requests:
16+
cpu: 500m
17+
memory: 512Mi
18+
upscalingMode: Default
19+
enableInTreeAutoscaling: false
20+
headGroupSpec:
21+
enableIngress: false
22+
rayStartParams:
23+
block: 'true'
24+
dashboard-host: 0.0.0.0
25+
num-gpus: '0'
26+
resources: '"{}"'
27+
serviceType: ClusterIP
28+
template:
29+
spec:
30+
containers:
31+
- image: quay.io/modh/ray@sha256:db667df1bc437a7b0965e8031e905d3ab04b86390d764d120e05ea5a5c18d1b4
32+
imagePullPolicy: Always
33+
lifecycle:
34+
preStop:
35+
exec:
36+
command:
37+
- /bin/sh
38+
- -c
39+
- ray stop
40+
name: ray-head
41+
ports:
42+
- containerPort: 6379
43+
name: gcs
44+
- containerPort: 8265
45+
name: dashboard
46+
- containerPort: 10001
47+
name: client
48+
resources:
49+
limits:
50+
cpu: 2
51+
memory: 8G
52+
requests:
53+
cpu: 2
54+
memory: 8G
55+
volumeMounts:
56+
- mountPath: /etc/pki/tls/certs/odh-trusted-ca-bundle.crt
57+
name: odh-trusted-ca-cert
58+
subPath: odh-trusted-ca-bundle.crt
59+
- mountPath: /etc/ssl/certs/odh-trusted-ca-bundle.crt
60+
name: odh-trusted-ca-cert
61+
subPath: odh-trusted-ca-bundle.crt
62+
- mountPath: /etc/pki/tls/certs/odh-ca-bundle.crt
63+
name: odh-ca-cert
64+
subPath: odh-ca-bundle.crt
65+
- mountPath: /etc/ssl/certs/odh-ca-bundle.crt
66+
name: odh-ca-cert
67+
subPath: odh-ca-bundle.crt
68+
volumes:
69+
- configMap:
70+
items:
71+
- key: ca-bundle.crt
72+
path: odh-trusted-ca-bundle.crt
73+
name: odh-trusted-ca-bundle
74+
optional: true
75+
name: odh-trusted-ca-cert
76+
- configMap:
77+
items:
78+
- key: odh-ca-bundle.crt
79+
path: odh-ca-bundle.crt
80+
name: odh-trusted-ca-bundle
81+
optional: true
82+
name: odh-ca-cert
83+
rayVersion: 2.35.0
84+
workerGroupSpecs:
85+
- groupName: small-group-default-cluster
86+
maxReplicas: 1
87+
minReplicas: 1
88+
rayStartParams:
89+
block: 'true'
90+
num-gpus: '0'
91+
resources: '"{}"'
92+
replicas: 1
93+
template:
94+
metadata:
95+
labels:
96+
controller-tools.k8s.io: '1.0'
97+
name: default-cluster
98+
namespace: ns
99+
spec:
100+
containers:
101+
- image: quay.io/modh/ray@sha256:db667df1bc437a7b0965e8031e905d3ab04b86390d764d120e05ea5a5c18d1b4
102+
imagePullPolicy: Always
103+
lifecycle:
104+
preStop:
105+
exec:
106+
command:
107+
- /bin/sh
108+
- -c
109+
- ray stop
110+
name: machine-learning
111+
resources:
112+
limits:
113+
cpu: 1
114+
memory: 2G
115+
requests:
116+
cpu: 1
117+
memory: 2G
118+
volumeMounts:
119+
- mountPath: /etc/pki/tls/certs/odh-trusted-ca-bundle.crt
120+
name: odh-trusted-ca-cert
121+
subPath: odh-trusted-ca-bundle.crt
122+
- mountPath: /etc/ssl/certs/odh-trusted-ca-bundle.crt
123+
name: odh-trusted-ca-cert
124+
subPath: odh-trusted-ca-bundle.crt
125+
- mountPath: /etc/pki/tls/certs/odh-ca-bundle.crt
126+
name: odh-ca-cert
127+
subPath: odh-ca-bundle.crt
128+
- mountPath: /etc/ssl/certs/odh-ca-bundle.crt
129+
name: odh-ca-cert
130+
subPath: odh-ca-bundle.crt
131+
volumes:
132+
- configMap:
133+
items:
134+
- key: ca-bundle.crt
135+
path: odh-trusted-ca-bundle.crt
136+
name: odh-trusted-ca-bundle
137+
optional: true
138+
name: odh-trusted-ca-cert
139+
- configMap:
140+
items:
141+
- key: odh-ca-bundle.crt
142+
path: odh-ca-bundle.crt
143+
name: odh-trusted-ca-bundle
144+
optional: true
145+
name: odh-ca-cert
+145
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,145 @@
1+
apiVersion: ray.io/v1
2+
kind: RayCluster
3+
metadata:
4+
labels:
5+
controller-tools.k8s.io: '1.0'
6+
name: default-cluster
7+
namespace: ns
8+
spec:
9+
autoscalerOptions:
10+
idleTimeoutSeconds: 60
11+
resources:
12+
limits:
13+
cpu: 500m
14+
memory: 512Mi
15+
requests:
16+
cpu: 500m
17+
memory: 512Mi
18+
upscalingMode: Default
19+
enableInTreeAutoscaling: false
20+
headGroupSpec:
21+
enableIngress: false
22+
rayStartParams:
23+
block: 'true'
24+
dashboard-host: 0.0.0.0
25+
num-gpus: '0'
26+
resources: '"{}"'
27+
serviceType: ClusterIP
28+
template:
29+
spec:
30+
containers:
31+
- image: quay.io/modh/ray@sha256:db667df1bc437a7b0965e8031e905d3ab04b86390d764d120e05ea5a5c18d1b4
32+
imagePullPolicy: Always
33+
lifecycle:
34+
preStop:
35+
exec:
36+
command:
37+
- /bin/sh
38+
- -c
39+
- ray stop
40+
name: ray-head
41+
ports:
42+
- containerPort: 6379
43+
name: gcs
44+
- containerPort: 8265
45+
name: dashboard
46+
- containerPort: 10001
47+
name: client
48+
resources:
49+
limits:
50+
cpu: 2
51+
memory: 8G
52+
requests:
53+
cpu: 2
54+
memory: 8G
55+
volumeMounts:
56+
- mountPath: /etc/pki/tls/certs/odh-trusted-ca-bundle.crt
57+
name: odh-trusted-ca-cert
58+
subPath: odh-trusted-ca-bundle.crt
59+
- mountPath: /etc/ssl/certs/odh-trusted-ca-bundle.crt
60+
name: odh-trusted-ca-cert
61+
subPath: odh-trusted-ca-bundle.crt
62+
- mountPath: /etc/pki/tls/certs/odh-ca-bundle.crt
63+
name: odh-ca-cert
64+
subPath: odh-ca-bundle.crt
65+
- mountPath: /etc/ssl/certs/odh-ca-bundle.crt
66+
name: odh-ca-cert
67+
subPath: odh-ca-bundle.crt
68+
volumes:
69+
- configMap:
70+
items:
71+
- key: ca-bundle.crt
72+
path: odh-trusted-ca-bundle.crt
73+
name: odh-trusted-ca-bundle
74+
optional: true
75+
name: odh-trusted-ca-cert
76+
- configMap:
77+
items:
78+
- key: odh-ca-bundle.crt
79+
path: odh-ca-bundle.crt
80+
name: odh-trusted-ca-bundle
81+
optional: true
82+
name: odh-ca-cert
83+
rayVersion: 2.35.0
84+
workerGroupSpecs:
85+
- groupName: small-group-default-cluster
86+
maxReplicas: 1
87+
minReplicas: 1
88+
rayStartParams:
89+
block: 'true'
90+
num-gpus: '0'
91+
resources: '"{}"'
92+
replicas: 1
93+
template:
94+
metadata:
95+
labels:
96+
controller-tools.k8s.io: '1.0'
97+
name: default-cluster
98+
namespace: ns
99+
spec:
100+
containers:
101+
- image: quay.io/modh/ray@sha256:db667df1bc437a7b0965e8031e905d3ab04b86390d764d120e05ea5a5c18d1b4
102+
imagePullPolicy: Always
103+
lifecycle:
104+
preStop:
105+
exec:
106+
command:
107+
- /bin/sh
108+
- -c
109+
- ray stop
110+
name: machine-learning
111+
resources:
112+
limits:
113+
cpu: 1
114+
memory: 2G
115+
requests:
116+
cpu: 1
117+
memory: 2G
118+
volumeMounts:
119+
- mountPath: /etc/pki/tls/certs/odh-trusted-ca-bundle.crt
120+
name: odh-trusted-ca-cert
121+
subPath: odh-trusted-ca-bundle.crt
122+
- mountPath: /etc/ssl/certs/odh-trusted-ca-bundle.crt
123+
name: odh-trusted-ca-cert
124+
subPath: odh-trusted-ca-bundle.crt
125+
- mountPath: /etc/pki/tls/certs/odh-ca-bundle.crt
126+
name: odh-ca-cert
127+
subPath: odh-ca-bundle.crt
128+
- mountPath: /etc/ssl/certs/odh-ca-bundle.crt
129+
name: odh-ca-cert
130+
subPath: odh-ca-bundle.crt
131+
volumes:
132+
- configMap:
133+
items:
134+
- key: ca-bundle.crt
135+
path: odh-trusted-ca-bundle.crt
136+
name: odh-trusted-ca-bundle
137+
optional: true
138+
name: odh-trusted-ca-cert
139+
- configMap:
140+
items:
141+
- key: odh-ca-bundle.crt
142+
path: odh-ca-bundle.crt
143+
name: odh-trusted-ca-bundle
144+
optional: true
145+
name: odh-ca-cert

0 commit comments

Comments
 (0)