From ef4473d3804dc19e8c1af894f5c296e4f5e35108 Mon Sep 17 00:00:00 2001 From: "Chris (wolcen) Thompson" <chris@agaric.coop> Date: Sat, 19 Apr 2025 19:58:35 -0400 Subject: [PATCH] Add some cruft...not actually active, but should this go modularly, this might help --- hosts/default/open-webui.nix | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 hosts/default/open-webui.nix diff --git a/hosts/default/open-webui.nix b/hosts/default/open-webui.nix new file mode 100644 index 0000000..f7724c5 --- /dev/null +++ b/hosts/default/open-webui.nix @@ -0,0 +1,25 @@ +{ + image = "ghcr.io/open-webui/open-webui:main"; + + environment = { + "TZ" = "America/New York"; + "OLLAMA_API_BASE_URL" = "http://127.0.0.1:11434/api"; + "OLLAMA_BASE_URL" = "http://127.0.0.1:11434"; + }; + + volumes = [ + "/home/wolcen/.openweb-ui:/app/backend/data" + ]; + + ports = [ + "127.0.0.1:3000:8080" # Ensures we listen only on localhost + ]; + + extraOptions = [ + "--pull=newer" # Pull if the image on the registry is newer + "--name=open-webui" + "--hostname=open-webui" + "--network=host" + "--add-host=host.containers.internal:host-gateway" + ]; +};