Skip to content

Commit

Permalink
add nvidia to config/publish
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcos20 committed Dec 13, 2023
1 parent 36dfd24 commit 018665f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion operator_engine/resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@ def create_configure_job(body, logger):
job["spec"]["template"]["spec"]["containers"][0]["volumeMounts"].append(
volume_mount
)
job["spec"]["template"]["spec"]["containers"][0]["resources"]["limits"]["nvidia.com/gpu"]="1"
job = jobs_common_params(job, logger)
create_job(logger, body, job)

Expand Down Expand Up @@ -633,7 +634,7 @@ def create_publish_job(body, logger):
job["spec"]["template"]["spec"]["containers"][0]["volumeMounts"].append(
volume_mount
)

job["spec"]["template"]["spec"]["containers"][0]["resources"]["limits"]["nvidia.com/gpu"]="1"
# set the account
job["spec"]["template"]["spec"]["serviceAccount"] = OperatorConfig.SERVICE_ACCOUNT
job["spec"]["template"]["spec"][
Expand Down

0 comments on commit 018665f

Please sign in to comment.