Skip to content

Latest commit

 

History

History
50 lines (35 loc) · 854 Bytes

File metadata and controls

50 lines (35 loc) · 854 Bytes

Job

In this training, we will create a job and parallelize its execution.

Navigate to the folder 17_job from CLI, before you get started.

Inspect job.yaml definition file and create the job

cat job.yaml
kubectl create -f job.yaml

Take a look at running Jobs and the Pods

It can take a while that the job is completed.

kubectl get pods,jobs

Increase the amount of executions to 10 and parallelize them

...
spec:
  completions: 10
  parallelism: 5
  template:
...

Re-create the job.

kubectl replace -f job.yaml  --force

Watch the running jobs and the pods

watch -n 1 kubectl get pods,jobs

Clean up

kubectl delete jobs --all

Jump to Home | Previous Training | Next Training