2021-02-08 18:00:34 -08:00
|
|
|
# Job to run a Ray program in its own pod. Assumes that a Ray cluster is already
|
|
|
|
# running.
|
|
|
|
apiVersion: batch/v1
|
|
|
|
kind: Job
|
|
|
|
metadata:
|
|
|
|
generateName: ray-test-job-
|
|
|
|
spec:
|
|
|
|
template:
|
|
|
|
spec:
|
|
|
|
restartPolicy: Never
|
|
|
|
containers:
|
|
|
|
- name: ray
|
|
|
|
image: rayproject/ray:nightly
|
|
|
|
imagePullPolicy: Always
|
2021-03-01 20:17:16 -08:00
|
|
|
command: [ "/bin/bash", "-c", "--" ]
|
2021-02-08 18:00:34 -08:00
|
|
|
args:
|
2021-03-01 20:17:16 -08:00
|
|
|
- "wget https://raw.githubusercontent.com/ray-project/ray/master/doc/kubernetes/example_scripts/job_example.py &&
|
|
|
|
python job_example.py"
|
2021-02-08 18:00:34 -08:00
|
|
|
resources:
|
|
|
|
requests:
|
|
|
|
cpu: 100m
|
|
|
|
memory: 512Mi
|