From 575f23cde998332c6a9f093ce58854e45c50b265 Mon Sep 17 00:00:00 2001 From: mindspawn Date: Sat, 8 Jun 2024 10:59:59 -0700 Subject: [PATCH] Update start.sh to be case-independent when testing env vars --- backend/start.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/start.sh b/backend/start.sh index 15fc568d3..16a004e45 100755 --- a/backend/start.sh +++ b/backend/start.sh @@ -20,12 +20,12 @@ if test "$WEBUI_SECRET_KEY $WEBUI_JWT_SECRET_KEY" = " "; then WEBUI_SECRET_KEY=$(cat "$KEY_FILE") fi -if [ "$USE_OLLAMA_DOCKER" = "true" ]; then +if [[ "${USE_OLLAMA_DOCKER,,}" == "true" ]]; then echo "USE_OLLAMA is set to true, starting ollama serve." ollama serve & fi -if [ "$USE_CUDA_DOCKER" = "true" ]; then +if [[ "${USE_CUDA_DOCKER,,}" == "true" ]]; then echo "CUDA is enabled, appending LD_LIBRARY_PATH to include torch/cudnn & cublas libraries." export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib/python3.11/site-packages/torch/lib:/usr/local/lib/python3.11/site-packages/nvidia/cudnn/lib" fi