ollama-server / entrypoint.sh
Yaya86's picture
Update entrypoint.sh
3f256eb verified
raw
history blame
505 Bytes
#!/bin/bash
# Starting server
echo "Starting server"
ollama serve &
sleep 1
# Splitting the models by comma and pulling each
IFS=',' read -ra MODELS <<< "$model"
for m in "${MODELS[@]}"; do
echo "Pulling $m"
ollama pull "nomic-embed-text"
sleep 5
ollama pull "mixtral"
# echo "Running $m"
# ollama run "$m"
# No need to sleep here unless you want to give some delay between each pull for some reason
done
# Keep the script running to prevent the container from exiting
wait