apiVersion: batch/v1
kind: Job
metadata:
  name: job-multi-serial
spec:
  completions: 5
  parallelism: 1                   #parallelism为1表示串行
  #completionMode: Indexed
  template:
    spec:
      containers:
      - name: job-multi-serial
        #image: busybox:1.30.0
        image: registry.cn-beijing.aliyuncs.com/wangxiaochun/busybox:1.32.0
        command: ["/bin/sh","-c","echo serial job; sleep 3"]
      restartPolicy: OnFailure
