Skip to content

Commit

Permalink
Merge branch 'fix_gds_env' into 'master'
Browse files Browse the repository at this point in the history
Apply env as per ClusterPolicy for GDS driver container

See merge request nvidia/kubernetes/gpu-operator!735
  • Loading branch information
shivamerla committed Jul 20, 2023
2 parents c64bc36 + 1d37893 commit 99f0ee5
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions controllers/object_controls.go
Original file line number Diff line number Diff line change
Expand Up @@ -2464,6 +2464,13 @@ func transformGDSContainer(obj *appsv1.DaemonSet, config *gpuv1.ClusterPolicySpe
}
}

// set/append environment variables for GDS container
if len(config.GPUDirectStorage.Env) > 0 {
for _, env := range config.GPUDirectStorage.Env {
setContainerEnv(&(obj.Spec.Template.Spec.Containers[i]), env.Name, env.Value)
}
}

// transform the nvidia-fs-ctr to use the openshift driver toolkit
// notify openshift driver toolkit container GDS is enabled
err = transformOpenShiftDriverToolkitContainer(obj, config, n, "nvidia-fs-ctr")
Expand Down

0 comments on commit 99f0ee5

Please sign in to comment.