Unverified Commit 2a63db4e authored by Someone Serge's avatar Someone Serge
Browse files

nixos/virtualisation.containers.cdi.dynamic.nvidia: expose driverLink

..shallowly
parent 65dbac72
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
{
  addDriverRunpath,
  glibc,
  jq,
  lib,
@@ -10,6 +11,7 @@
let
  mountOptions = { options = ["ro" "nosuid" "nodev" "bind"]; };
  mounts = [
    # FIXME: Making /usr mounts optional
    { hostPath = lib.getExe' nvidia-driver "nvidia-cuda-mps-control";
      containerPath = "/usr/bin/nvidia-cuda-mps-control"; }
    { hostPath = lib.getExe' nvidia-driver "nvidia-cuda-mps-server";
@@ -24,6 +26,14 @@ let
      containerPath = "/usr/bin/nvidia-ctk"; }
    { hostPath = "${lib.getLib glibc}/lib";
      containerPath = "${lib.getLib glibc}/lib"; }

    # FIXME: use closureinfo
    {
      hostPath = addDriverRunpath.driverLink;
      containerPath = addDriverRunpath.driverLink;
    }
    { hostPath = "${lib.getLib glibc}/lib";
      containerPath = "${lib.getLib glibc}/lib"; }
    { hostPath = "${lib.getLib glibc}/lib64";
      containerPath = "${lib.getLib glibc}/lib64"; }
  ];