Skip to content

Commit 6c94074

Browse files
committed
fix linux docker network mode [skip ci]
1 parent bcabd2e commit 6c94074

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

start.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,12 @@ handle_ollama_env() {
297297

298298
# use docker internal for the Ollama host
299299
OLLAMA_HOST=$DOCKER_HOST
300-
DKN_DOCKER_NETWORK_MODE=bridge
300+
301+
# if the OS is Linux, use host network mode
302+
# otherwise bridge is fine, as set above
303+
if [ "$OS" = "Linux" ]; then
304+
DKN_DOCKER_NETWORK_MODE=host
305+
fi
301306
fi
302307

303308
echo "Ollama host: $OLLAMA_HOST (network mode: $DKN_DOCKER_NETWORK_MODE)"

0 commit comments

Comments
 (0)