9 lines
356 B
Bash
Executable file
9 lines
356 B
Bash
Executable file
#!/bin/bash
|
|
# Restart danable API safely: pattern lives in this file, never in the caller cmdline.
|
|
pkill -f 'uvicorn src\.main:app' 2>/dev/null
|
|
sleep 2
|
|
cd /home/hailt/danagble/backend
|
|
setsid -f .venv/bin/python -m uvicorn src.main:app --host 0.0.0.0 --port 8000 </dev/null >>/tmp/danable-api.log 2>&1
|
|
sleep 4
|
|
curl -s -m 5 localhost:8000/api/v1/health
|
|
echo
|