From 46adf8e9f055df62748391dc5290cdf68401d2fa Mon Sep 17 00:00:00 2001 From: Bryan Ramos Date: Tue, 14 Apr 2026 00:41:39 -0400 Subject: [PATCH] seperate routing for llama & stack --- system/machines/server/modules/nginx/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/system/machines/server/modules/nginx/default.nix b/system/machines/server/modules/nginx/default.nix index cac2217..32d754b 100644 --- a/system/machines/server/modules/nginx/default.nix +++ b/system/machines/server/modules/nginx/default.nix @@ -140,15 +140,16 @@ in useACMEHost = domain; forceSSL = true; - # Web UI — llama.cpp chat interface (browser) + # Web UI + llama.cpp API (browser, /v1/* calls from the UI) # Auth handled by llama.cpp itself (--api-key flag) locations."/" = { proxyPass = "http://192.168.0.23:8000"; proxyWebsockets = true; }; - # API — Llama Stack (opencode, programmatic clients) - locations."/v1/" = { + # Llama Stack API (opencode, programmatic clients) + # Clients use baseURL: https://ai.ramos.codes/stack/v1 + locations."/stack/v1/" = { proxyPass = "http://192.168.0.23:8321/v1/"; proxyWebsockets = true; extraConfig = apiKeyAuth + '' @@ -158,7 +159,7 @@ in }; # Llama Stack beta API - locations."/v1beta/" = { + locations."/stack/v1beta/" = { proxyPass = "http://192.168.0.23:8321/v1beta/"; proxyWebsockets = true; extraConfig = apiKeyAuth + ''