mirror of
https://codeberg.org/muon/home.git
synced 2025-12-05 23:57:46 +00:00
Add support for websockets
This commit is contained in:
parent
d52d63ea69
commit
5785a3bb84
2 changed files with 8 additions and 3 deletions
|
|
@ -15,7 +15,7 @@ in with lib; {
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
services.ollama = {
|
services.ollama = {
|
||||||
enable = true;
|
enable = true;
|
||||||
loadModels = [ "deepseek-r1:7b" ];
|
loadModels = [ "deepseek-r1:1.5b" "deepseek-r1:7b" "deepseek-r1:8b" ];
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -29,7 +29,7 @@ in with lib; {
|
||||||
SCARF_NO_ANALYTICS = "True";
|
SCARF_NO_ANALYTICS = "True";
|
||||||
OLLAMA_API_BASE_URL = "http://127.0.0.1:11434";
|
OLLAMA_API_BASE_URL = "http://127.0.0.1:11434";
|
||||||
# Disable authentication
|
# Disable authentication
|
||||||
WEBUI_AUTH = "False";
|
# WEBUI_AUTH = "False";
|
||||||
};
|
};
|
||||||
|
|
||||||
inherit port;
|
inherit port;
|
||||||
|
|
|
||||||
|
|
@ -90,7 +90,12 @@ in with lib; {
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
};
|
};
|
||||||
proxy = port:
|
proxy = port:
|
||||||
base { "/".proxyPass = "http://${cfg.ip}:${toString port}/"; };
|
base {
|
||||||
|
"/" = {
|
||||||
|
proxyPass = "http://${cfg.ip}:${toString port}/";
|
||||||
|
proxyWebsockets = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
in mapAttrs' (name: port:
|
in mapAttrs' (name: port:
|
||||||
nameValuePair ("${name}.${cfg.domain}")
|
nameValuePair ("${name}.${cfg.domain}")
|
||||||
# (proxy port // { default = true; })) cfg.ports;
|
# (proxy port // { default = true; })) cfg.ports;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue