Skip to content

Commit

Permalink
Merge pull request #14 from raymondpau/fix-model-filename
Browse files Browse the repository at this point in the history
fix: Fix failure to load  successfully downloaded model
  • Loading branch information
mudler authored Aug 24, 2023
2 parents 98061d6 + 40338c6 commit b90804f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions charts/local-ai/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ spec:
auth=$(echo "$line" | awk '{print $2}')
if [ -n "$url" ]; then
filename=$(basename "$url")
filename=$(basename "$url" .bin)
if [ "$FORCE_DOWNLOAD" = false ] && [ -f "$MODEL_DIR/$filename" ]; then
echo "File $filename already exists. Skipping download."
Expand All @@ -70,9 +70,9 @@ spec:
echo "Downloading $filename"
if [ -n "$auth" ]; then
wget -P "$MODEL_DIR" --header "Authorization: Basic $auth" "$url"
wget --header "Authorization: Basic $auth" "$url" -O "$MODEL_DIR/$filename"
else
wget -P "$MODEL_DIR" "$url"
wget "$url" -O "$MODEL_DIR/$filename"
fi
if [ "$?" -ne 0 ]; then
Expand Down

0 comments on commit b90804f

Please sign in to comment.