only keep templates in git

This commit is contained in:
j 2021-11-15 11:49:19 +00:00
parent 491d8c4629
commit 0cfb499594
4 changed files with 12 additions and 3 deletions

2
.gitignore vendored
View File

@ -36,3 +36,5 @@ pandora/gunicorn_config.py
.DS_Store .DS_Store
.env .env
overlay/ overlay/
pandora/encoding.conf
pandora/tasks.conf

13
ctl
View File

@ -43,9 +43,11 @@ if [ "$action" = "init" ]; then
done done
cd ${BASE} cd ${BASE}
$SUDO ./bin/pip install -r requirements.txt $SUDO ./bin/pip install -r requirements.txt
if [ ! -e pandora/gunicorn_config.py ]; then for template in gunicorn_config.py encoding.conf tasks.conf; do
$SUDO cp pandora/gunicorn_config.py.in pandora/gunicorn_config.py if [ ! -e pandora/$template ]; then
fi $SUDO cp pandora/${template}.in pandora/$template
fi
done
exit 0 exit 0
fi fi
@ -77,6 +79,11 @@ if [ "$action" = "install" ]; then
BASE=`pwd` BASE=`pwd`
if [ -x /bin/systemctl ]; then if [ -x /bin/systemctl ]; then
if [ -d /etc/systemd/system/ ]; then if [ -d /etc/systemd/system/ ]; then
for template in gunicorn_config.py encoding.conf tasks.conf; do
if [ ! -e pandora/$template ]; then
$SUDO cp pandora/${template}.in pandora/$template
fi
done
for service in $SERVICES; do for service in $SERVICES; do
if [ -e /lib/systemd/system/${service}.service ]; then if [ -e /lib/systemd/system/${service}.service ]; then
rm -f /lib/systemd/system/${service}.service \ rm -f /lib/systemd/system/${service}.service \