New Ollama.nix, the ai.nix did not work out. Added ZED-editor as separate app
This commit is contained in:
+307
-305
File diff suppressed because it is too large
Load Diff
@@ -1642,15 +1642,17 @@ This Home Manager Nix module (ai.nix) installs the Ollama package and configures
|
|||||||
|
|
||||||
#+begin_src nix :tangle home/apps/ollama.nix :noweb tangle :mkdirp yes
|
#+begin_src nix :tangle home/apps/ollama.nix :noweb tangle :mkdirp yes
|
||||||
{ config, lib, pkgs, flakeRoot, ... }:
|
{ config, lib, pkgs, flakeRoot, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
ollamaConfPath = flakeRoot + "/assets/conf/apps/ai/ollama/ollama.conf";
|
ollamaConfPath = flakeRoot + "/assets/conf/apps/ai/ollama/ollama.conf";
|
||||||
|
ollamaEnv = builtins.readFile ollamaConfPath;
|
||||||
in
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
services.ollama = {
|
services.ollama = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.ollama;
|
package = pkgs.ollama;
|
||||||
configFile = ollamaConfPath;
|
extraConfig = lib.mkForce ollamaEnv;
|
||||||
environmentFile = builtins.readFile ollamaConfPath;
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,15 @@
|
|||||||
{ config, lib, pkgs, flakeRoot, ... }:
|
{ config, lib, pkgs, flakeRoot, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
ollamaConfPath = flakeRoot + "/assets/conf/apps/ai/ollama/ollama.conf";
|
ollamaConfPath = flakeRoot + "/assets/conf/apps/ai/ollama/ollama.conf";
|
||||||
|
ollamaEnv = builtins.readFile ollamaConfPath;
|
||||||
in
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
services.ollama = {
|
services.ollama = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.ollama;
|
package = pkgs.ollama;
|
||||||
configFile = ollamaConfPath;
|
extraConfig = lib.mkForce ollamaEnv;
|
||||||
environmentFile = builtins.readFile ollamaConfPath;
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user