diff --git a/hosts/architect/llm.nix b/hosts/architect/llm.nix index ce62c55..a1a8971 100644 --- a/hosts/architect/llm.nix +++ b/hosts/architect/llm.nix @@ -10,16 +10,20 @@ in systemPackages = [ ollamaPkg ]; }; - services.ollama = { - enable = true; + services = { + ollama = { + enable = true; - package = ollamaPkg; - acceleration = "cuda"; - environmentVariables = { - OLLAMA_FLASH_ATTENTION = "1"; - OLLAMA_NUM_PARALLEL = "2"; - OLLAMA_KV_CACHE_TYPE = "q8_0"; + package = ollamaPkg; + acceleration = "cuda"; + environmentVariables = { + OLLAMA_FLASH_ATTENTION = "1"; + OLLAMA_NUM_PARALLEL = "2"; + OLLAMA_KV_CACHE_TYPE = "q8_0"; + }; }; + + open-webui.enable = true; }; architect.vhost.${backendDomain} = { @@ -38,4 +42,15 @@ in ''; }; }; + + architect.vhost.${frontendDomain} = { + dnsInterfaces = [ "tailscale" "lan" ]; + + locations."/" = { + host = config.services.open-webui.host; + port = config.services.open-webui.port; + allowLan = true; + allowWAN = true; + }; + }; }