mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-06 19:08:59 -05:00
[GH-ISSUE #10833] Connection failed for Ollama with default docker command for Ollama #16047
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @FabricSoul on GitHub (Feb 26, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/10833
Bug Report
Installation Method
Docker container installation using:
Environment
Confirmation:
Expected Behavior:
Open WebUI should connect to the Ollama API running on the host machine, allowing me to use Ollama models within the Open WebUI interface.
Actual Behavior:
The Docker container cannot connect to the Ollama API that's running locally on my NixOS machine. The logs show connection errors with the message: "Cannot connect to host host.docker.internal:11434 ssl:default [Connect call failed ('172.17.0.1', 11434)]"
Description
Bug Summary:
Open WebUI Docker container fails to connect to locally hosted Ollama API on NixOS despite using the
--add-host=host.docker.internal:host-gatewayflag, which should allow the container to access the host network.Reproduction Details
Steps to Reproduce:
Logs and Screenshots
Docker Container Logs:
Browser Console Logs:
[Need browser console logs if available]
Additional Information
host = "0.0.0.0"in the NixOS configuration.--add-host=host.docker.internal:host-gatewayflag to facilitate host access.I suspect this might be related to how NixOS handles networking between Docker containers and host services, possibly requiring additional configuration beyond the standard Docker networking flags.
Note
I have checked for similar issues in the repositories before submitting this bug report and have confirmed that this is a reproducible issue specific to the NixOS environment.