mirror of
https://github.com/juspay/services-flake.git
synced 2024-09-11 12:26:04 +03:00
ported from: https://github.com/shivaraj-bh/ollama-flake/blob/main/services/open-webui.nix This was also recently upstreamed to [nixpkgs](https://github.com/NixOS/nixpkgs/tree/master): https://github.com/NixOS/nixpkgs/pull/316248 --------- Co-authored-by: Pol Dellaiera <pol.dellaiera@protonmail.com> Co-authored-by: Sridhar Ratnakumar <3998+srid@users.noreply.github.com>
22 lines
571 B
Nix
22 lines
571 B
Nix
{ pkgs, ... }: {
|
|
services.open-webui."open-webui1" = {
|
|
enable = true;
|
|
environment = {
|
|
# Requires network connection
|
|
RAG_EMBEDDING_MODEL = "";
|
|
};
|
|
};
|
|
|
|
settings.processes.test = {
|
|
command = pkgs.writeShellApplication {
|
|
runtimeInputs = [ pkgs.curl ];
|
|
text = ''
|
|
# Avoid printing the entire HTML page on the stdout, we just want to know if the page is active.
|
|
curl http://127.0.0.1:1111 > /dev/null
|
|
'';
|
|
name = "open-webui-test";
|
|
};
|
|
depends_on."open-webui1".condition = "process_healthy";
|
|
};
|
|
}
|