From 49a2d8e5f1c512b483dccbe8e170ecce1b1025de Mon Sep 17 00:00:00 2001 From: shunki-fujita Date: Wed, 18 Oct 2023 05:28:11 +0000 Subject: [PATCH] Enable cpu specification in jobConfig --- api/v1beta2/job_types.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/api/v1beta2/job_types.go b/api/v1beta2/job_types.go index d947a327c..fd56f2b76 100644 --- a/api/v1beta2/job_types.go +++ b/api/v1beta2/job_types.go @@ -30,6 +30,16 @@ type JobConfig struct { // +optional Threads int `json:"threads,omitempty"` + // CPU is the amount of CPU requested for the Pod. + // +kubebuilder:default="4" + // +optional + CPU *resource.Quantity `json:"cpu,omitempty"` + + // MaxCPU is the amount of maximum CPU for the Pod. + // +nullable + // +optional + MaxCPU *resource.Quantity `json:"maxCpu,omitempty"` + // Memory is the amount of memory requested for the Pod. // +kubebuilder:default="4Gi" // +nullable