From 16d3050eb8f615ae9bfc42d66fa5f28db9113c2c Mon Sep 17 00:00:00 2001 From: Simon Gardling Date: Thu, 8 Jan 2026 05:41:10 -0500 Subject: [PATCH] fully remove llama-cpp --- configuration.nix | 2 -- flake.nix | 5 ----- services/llama-cpp.nix | 43 ------------------------------------------ 3 files changed, 50 deletions(-) delete mode 100644 services/llama-cpp.nix diff --git a/configuration.nix b/configuration.nix index 7f4ef5e..3f496a2 100644 --- a/configuration.nix +++ b/configuration.nix @@ -33,8 +33,6 @@ ./services/soulseek.nix - # ./services/llama-cpp.nix - ./services/ups.nix ./services/bitwarden.nix diff --git a/flake.nix b/flake.nix index bb7096f..cff2c74 100644 --- a/flake.nix +++ b/flake.nix @@ -28,11 +28,6 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - llamacpp = { - url = "github:ggml-org/llama.cpp"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - srvos = { url = "github:nix-community/srvos"; inputs.nixpkgs.follows = "nixpkgs"; diff --git a/services/llama-cpp.nix b/services/llama-cpp.nix deleted file mode 100644 index 9a57449..0000000 --- a/services/llama-cpp.nix +++ /dev/null @@ -1,43 +0,0 @@ -{ - pkgs, - service_configs, - config, - inputs, - lib, - ... -}: -{ - services.llama-cpp = { - enable = true; - model = builtins.toString ( - pkgs.fetchurl { - url = "https://huggingface.co/unsloth/Apriel-1.5-15b-Thinker-GGUF/resolve/main/Apriel-1.5-15b-Thinker-Q4_0.gguf"; - sha256 = "4d9439b76b6f4380ab5205617c1ef3d10b0e8897146a0a7ccb7155bca1771df7"; - } - ); - port = service_configs.ports.llama_cpp; - host = "0.0.0.0"; - # vulkan broken: https://github.com/ggml-org/llama.cpp/issues/13801 - package = ( - lib.optimizePackage ( - inputs.llamacpp.packages.${pkgs.system}.vulkan.overrideAttrs (old: { - postPatch = ""; - }) - ) - ); - extraFlags = [ - "-ngl" - "12" - "-c" - "16384" - ]; - }; - - # have to do this in order to get vulkan to work - systemd.services.llama-cpp.serviceConfig.DynamicUser = lib.mkForce false; - - services.caddy.virtualHosts."llm.${service_configs.https.domain}".extraConfig = '' - import ${config.age.secrets.caddy_auth.path} - reverse_proxy :${builtins.toString config.services.llama-cpp.port} - ''; -}