ollama-api-test / start.sh
YussefGAFeer's picture
Create start.sh
965ff20 verified
raw
history blame contribute delete
329 Bytes
#!/bin/bash
set -e
# Start Ollama in the background
nohup ollama serve > /dev/null 2>&1 &
# Wait for Ollama to be ready
until curl -s http://localhost:11434/api/tags > /dev/null; do
echo "Waiting for Ollama to start..."
sleep 1
done
# Start the FastAPI application
exec uvicorn app:app --host 0.0.0.0 --port 8000 --reload