Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #5. I'm very new to Nix and so would appreciate a code style review if that's possible. This is a little closer to 'prototype' than 'good to go' but I figured it'd be worth pushing up regardless as others will likely benefit!
Description of changes
After this MR, setting
virtualisation.docker.enableNvidia = true
will work on Jetsons. Unfortunately there are two other flags which need handling:systemd.enableUnifiedCgroupHierarchy = false
or receive errors. I assume that with nixpkgs changes this will eventually fade.assertion = cfg.enableNvidia -> config.hardware.opengl.driSupport32Bit or false
which with a big stick could be done byassertions = lib.mkForce []
. I have a PR for this here: nixos/virtualisation.docker: Do not assert 32 bit libraries available on ARM NixOS/nixpkgs#246179 but obviously it will be quite some time before it shows up in stable channels.Testing
Tested on orin-nano. Tested by starting l4t-base, apt installing cuda, compiling samples, and running them (with success results).