about summary refs log tree commit diff stats
path: root/modules/by-name
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--modules/by-name/ol/ollama/module.nix7
1 files changed, 6 insertions, 1 deletions
diff --git a/modules/by-name/ol/ollama/module.nix b/modules/by-name/ol/ollama/module.nix
index 418a1851..022770b0 100644
--- a/modules/by-name/ol/ollama/module.nix
+++ b/modules/by-name/ol/ollama/module.nix
@@ -11,7 +11,12 @@ in {
 
   config = lib.mkIf cfg.enable {
     soispha.impermanence.directories = [
-      config.services.ollama.home
+      # Ollama's systemd services tries to do create the directory under
+      # `/var/lib/private/ollama` and then symlink `/var/lib/ollama` to that, when
+      # `DynamicUsers` is true. Thus we need to persist the private directory and not the
+      # resulting symlink one.
+      # Relevant issue: https://github.com/nix-community/impermanence/issues/93
+      "/var/lib/private/ollama"
     ];
 
     services.ollama = {