From 3713b0b5c5bf270f411f43a4d3fde44bb5be329d Mon Sep 17 00:00:00 2001 From: Daniel Vega-Myhre Date: Fri, 26 Jul 2024 23:09:51 +0000 Subject: [PATCH] add example for coordinator --- examples/simple/coordinator.yaml | 43 ++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 examples/simple/coordinator.yaml diff --git a/examples/simple/coordinator.yaml b/examples/simple/coordinator.yaml new file mode 100644 index 000000000..226e51133 --- /dev/null +++ b/examples/simple/coordinator.yaml @@ -0,0 +1,43 @@ +apiVersion: jobset.x-k8s.io/v1alpha2 +kind: JobSet +metadata: + name: coordinator-example +spec: + # label and annotate jobs and pods with stable network endpoint of the designated + # coordinator pod: + # jobset.sigs.k8s.io/coordinator=coordinator-example-driver-0-0.coordinator-example + coordinator: + replicatedJob: driver + jobIndex: 0 + podIndex: 0 + replicatedJobs: + - name: workers + template: + spec: + parallelism: 4 + completions: 4 + backoffLimit: 0 + template: + spec: + containers: + - name: sleep + image: busybox + command: + - sleep + args: + - 100s + - name: driver + template: + spec: + parallelism: 1 + completions: 1 + backoffLimit: 0 + template: + spec: + containers: + - name: sleep + image: busybox + command: + - sleep + args: + - 100s