mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
Merge pull request #315347 from NixOS/backport-314840-to-release-24.05
[Backport release-24.05] hardware/nvidia-container-toolkit: mount `nvidia-driver/share`
This commit is contained in:
commit
8872b57bcd
1 changed files with 6 additions and 2 deletions
|
@ -69,14 +69,18 @@
|
|||
virtualisation.docker.daemon.settings = lib.mkIf
|
||||
(config.hardware.nvidia-container-toolkit.enable &&
|
||||
(lib.versionAtLeast config.virtualisation.docker.package.version "25")) {
|
||||
features.cdi = true;
|
||||
};
|
||||
features.cdi = true;
|
||||
};
|
||||
|
||||
hardware.nvidia-container-toolkit.mounts = let
|
||||
nvidia-driver = config.hardware.nvidia.package;
|
||||
in (lib.mkMerge [
|
||||
[{ hostPath = pkgs.addDriverRunpath.driverLink;
|
||||
containerPath = pkgs.addDriverRunpath.driverLink; }
|
||||
{ hostPath = "${lib.getLib nvidia-driver}/etc";
|
||||
containerPath = "${lib.getLib nvidia-driver}/etc"; }
|
||||
{ hostPath = "${lib.getLib nvidia-driver}/share";
|
||||
containerPath = "${lib.getLib nvidia-driver}/share"; }
|
||||
{ hostPath = "${lib.getLib pkgs.glibc}/lib";
|
||||
containerPath = "${lib.getLib pkgs.glibc}/lib"; }
|
||||
{ hostPath = "${lib.getLib pkgs.glibc}/lib64";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue