From 62ad7255bae131ff46be171f0563f4734b8ba9b5 Mon Sep 17 00:00:00 2001 From: Leyla Becker Date: Sun, 29 Sep 2024 12:15:15 -0500 Subject: [PATCH] added ollama plugin --- users/leyla/default.nix | 26 +++++++++++++++++--------- users/leyla/packages.nix | 2 ++ 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/users/leyla/default.nix b/users/leyla/default.nix index 1cd30fe..69f8193 100644 --- a/users/leyla/default.nix +++ b/users/leyla/default.nix @@ -51,15 +51,23 @@ in { } ); - # TODO: this should reference the home directory from the user config - services.openssh.hostKeys = [ - { - comment = "leyla@" + config.networking.hostName; - path = "/home/leyla/.ssh/leyla_" + config.networking.hostName + "_ed25519"; - rounds = 100; - type = "ed25519"; - } - ]; + services = { + ollama = { + enable = true; + acceleration = lib.mkIf cfg.hasGPU "cuda"; + }; + + + # TODO: this should reference the home directory from the user config + openssh.hostKeys = [ + { + comment = "leyla@" + config.networking.hostName; + path = "/home/leyla/.ssh/leyla_" + config.networking.hostName + "_ed25519"; + rounds = 100; + type = "ed25519"; + } + ]; + }; home-manager.users.leyla = lib.mkIf (cfg.isFullUser || cfg.isThinUser) (import ./home.nix); }; diff --git a/users/leyla/packages.nix b/users/leyla/packages.nix index e206d22..a5960d9 100644 --- a/users/leyla/packages.nix +++ b/users/leyla/packages.nix @@ -106,6 +106,8 @@ in { # misc extensions bungcip.better-toml + + open-vsx."10nates".ollama-autocoder ] ++ (with vscode-marketplace; [ # js extensions