mirror of
https://github.com/juspay/services-flake.git
synced 2024-10-05 16:37:38 +03:00
docs(ollama): Document how to allow unfree packages (in this case, for proprietary nvidia packages)
This commit is contained in:
parent
b291b6f35d
commit
fb6de01eb6
@ -23,6 +23,24 @@ By default Ollama uses the CPU for inference. To enable GPU acceleration:
|
||||
|
||||
For NVIDIA GPUs.
|
||||
|
||||
Firstly, allow unfree packages:
|
||||
|
||||
```nix
|
||||
# Inside perSystem = { system, ... }: { ...
|
||||
{
|
||||
imports = [
|
||||
"${inputs.nixpkgs}/nixos/modules/misc/nixpkgs.nix"
|
||||
];
|
||||
nixpkgs = {
|
||||
hostPlatform = system;
|
||||
# Required for CUDA
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
And then enable CUDA acceleration:
|
||||
|
||||
```nix
|
||||
# In `perSystem.process-compose.<name>`
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user