forked from freeleaps/freeleaps-pub
Update for pip check when restart backend service
This commit is contained in:
parent
c16b869f6f
commit
736d426cc1
@ -867,6 +867,12 @@ docker exec -i "$DEVBOX_NAME" bash <<EOF
|
||||
./start_webapi.sh > /home/devbox/logs/backend.logs 2>&1 &
|
||||
else
|
||||
echo "==> [BACKEND] Backend dependencies already installed. Skipping installation."
|
||||
# Check if all dependencies are installed, if not, install them
|
||||
if ! pip check; then
|
||||
echo "==> [BACKEND] Some dependencies are missing. Reinstalling..."
|
||||
pip install -r /home/devbox/freeleaps/apps/requirements.txt
|
||||
fi
|
||||
|
||||
# Check if the backend service is already running
|
||||
SERVICE_API_ACCESS_PORT=\$(cat /home/devbox/.devbox-backend-port)
|
||||
uvicorn freeleaps.webapi.main:app --reload --host 0.0.0.0 --port \$SERVICE_API_ACCESS_PORT > /home/devbox/logs/backend.logs 2>&1 &
|
||||
|
||||
Loading…
Reference in New Issue
Block a user