Files
CloudGPT/bin/run.sh
2025-11-27 18:18:43 +01:00

22 lines
426 B
Bash

#!/bin/sh
git pull -C /app
if [ ! -d /app/.venv ];
then
logger "generating python virtual-env"
python3 -m venv /app/.venv
echo '.venv' >> /app/.gitignore
fi
source /app/.venv/bin/activate
if [ -f /app/requirements.txt ];
then
logger "updating python packages"
pip3 install -U -r /app/requirements.txt
fi
logger "starting CloudGPT"
python3 /app/bin/CloudGPT.py 2>&1 | while IFS= read -r line; do logger "$line"; done