added llama-stack

This commit is contained in:
Bryan Ramos 2026-04-13 23:12:50 -04:00
parent 07586a80ee
commit c41a6ff637
4 changed files with 35 additions and 27 deletions

View file

@ -22,7 +22,6 @@ in
'';
};
searxng.enable = mkEnableOption "Publicly exposed SearXNG endpoint with secret path via sops";
};
config = mkIf cfg.enable {
@ -116,15 +115,6 @@ in
};
};
virtualHosts."searxng.${domain}" = mkIf cfg.searxng.enable {
useACMEHost = domain;
forceSSL = true;
locations."/".return = "404";
extraConfig = ''
include ${config.sops.templates."nginx-searxng-location.conf".path};
'';
};
virtualHosts."chat.${domain}" = {
useACMEHost = domain;
forceSSL = true;
@ -139,8 +129,19 @@ in
useACMEHost = domain;
forceSSL = true;
locations."/" = {
proxyPass = "http://192.168.0.23:8000";
proxyPass = "http://192.168.0.23:8321";
proxyWebsockets = true;
extraConfig = ''
# API key auth — validated against the sops-managed key
set $api_key "";
if ($http_authorization ~* "^Bearer (.+)$") {
set $api_key $1;
}
if ($api_key = "") {
return 401 '{"error": "Missing Authorization header"}';
}
include ${config.sops.templates."nginx-ai-auth.conf".path};
'';
};
};