summaryrefslogtreecommitdiff
path: root/install
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2020-01-31 16:41:38 +0100
committerÉtienne Loks <etienne.loks@iggdrasil.net>2020-07-01 18:02:28 +0200
commit8481e06e8e809a90ae19f8bfeb2153080793d2de (patch)
tree46b17302c54c123d78bad8543b9ca818ac427e7e /install
parent1f89e132119d101b6b8844c49b4cd06df009e308 (diff)
downloadIshtar-8481e06e8e809a90ae19f8bfeb2153080793d2de.tar.bz2
Ishtar-8481e06e8e809a90ae19f8bfeb2153080793d2de.zip
ishtar-prepare-instance: fix bad evaluation of variables
Diffstat (limited to 'install')
-rwxr-xr-xinstall/ishtar-prepare-instance14
1 files changed, 7 insertions, 7 deletions
diff --git a/install/ishtar-prepare-instance b/install/ishtar-prepare-instance
index c670cb6c7..05da0f4db 100755
--- a/install/ishtar-prepare-instance
+++ b/install/ishtar-prepare-instance
@@ -223,7 +223,7 @@ EOF
echo " - not present, creating"
createuser --echo --adduser --createdb --encrypted $DB_NAME
psql --command "ALTER USER \""$DB_NAME"\" with password '"$DB_PASSWORD"';"
- createdb -T template_postgis --echo --owner $DB_NAME --encoding UNICODE $DB_NAME
+ createdb -T template0 --echo --owner $DB_NAME --encoding UNICODE $DB_NAME
psql -d $DB_NAME -c "CREATE EXTENSION postgis;"
else
echo " - already present"
@@ -253,7 +253,7 @@ EOF
# manage celery daemon
CELERY_CONF=""
- if [ -v USE_CELERY ]; then
+ if [ -v $USE_CELERY ]; then
RBMQ_PASSWORD=$(apg -a 0 -M ncl -n 1 -x 10 -m 10)
/usr/sbin/rabbitmqctl add_vhost /ishtar$INSTANCE
/usr/sbin/rabbitmqctl add_user ishtar$INSTANCE $RBMQ_PASSWORD
@@ -277,7 +277,7 @@ EOF
### __init__.py
cd $INSTANCE
- if [ -v USE_CELERY ]; then
+ if [ -v $USE_CELERY ]; then
ln -s __init__.py.celery.sample __init__.py
else
ln -s __init__.py.base.sample __init__.py
@@ -302,11 +302,11 @@ EOF
echo $CELERY_CONF >> "$INSTANCE/local_settings.py"
- if [ -v USE_CELERY ]; then
+ if [ -v $USE_CELERY ]; then
echo "USE_BACKGROUND_TASK = True" >> "$INSTANCE/local_settings.py"
fi
- if [ -v USE_LIBREOFFICE ]; then
+ if [ -v $USE_LIBREOFFICE ]; then
echo "USE_LIBREOFFICE = True" >> "$INSTANCE/local_settings.py"
fi
@@ -382,7 +382,7 @@ EOF
### Celery - start worker
- if [ -v USE_CELERY ]; then
+ if [ -v $USE_CELERY ]; then
systemctl enable celery-$INSTANCE
systemctl start celery-$INSTANCE
fi
@@ -405,7 +405,7 @@ EOF
echo " And then enjoy ishtar!"
echo ""
- if [ -v USE_CELERY ]; then
+ if [ -v $USE_CELERY ]; then
cat >&2 <<-'EOF'
If you use monit a configuration file has been generated for the celery