A TFJob is a Kubernetes custom resource that specifies a distributed TensorFlow training job. Its controller watches submitted objects and creates the required training Pods, letting data science teams provide TensorFlow code without directly managing infrastructure. section 8.3.1
The specification describes replica roles, counts, container images, commands, and restart behavior. A worker configuration with two replicas produces two worker Pods running the same MNIST training container. section 8.3.1
Two-worker training job
A TFJob can use apiVersion kubeflow.org/v1, kind TFJob, and a Worker replica count of 2. The worker template runs a TensorFlow image with a Python training command, learning rate, batch size, and OnFailure restart policy. Submit it with kubectl create -f.
TFJobs also fit inside workflow automation. An Argo step can create a TFJob, wait for two workers to succeed or any worker to fail, and then pass control to model selection and serving. section 9.4.1
