first upload
This commit is contained in:
21
bin/run.sh
Normal file
21
bin/run.sh
Normal file
@ -0,0 +1,21 @@
|
||||
#!/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
|
||||
Reference in New Issue
Block a user