commit 4d5410f6930c88a447f4584d1229c47dc2be64b7
parent 3e543fb8c563f6a4e68148b43ea24d30285d6914
Author: Marcello Stanisci <stanisci.m@gmail.com>
Date: Thu, 27 Jun 2019 11:50:01 +0200
shared-data -> taler-data
Diffstat:
1 file changed, 12 insertions(+), 18 deletions(-)
diff --git a/bin/taler-deployment-hier b/bin/taler-deployment-hier
@@ -13,42 +13,36 @@ if test -z $TALER_CONFIG_ENV; then
exit 1
fi
-# Check shared-data/ exists
-if ! test -e $SHARED_DATA; then
- echo "Please bootstrap your setup first (run 'bootstrap-bluegreen' script?)."
- exit 1
-fi
-
if ! test -e $HOME/.config/taler.conf; then
echo "Please generate config first (taler-deployment-config-generate)."
exit 1
fi
-SHARED_DATA=$(taler-config -s paths -o taler_deployment_shared -f)
+TALER_DATA=$(taler-config -s paths -o taler_deployment_data -f)
# Check if shared-data/ is clean.
-if test -e $SHARED_DATA/hier.lock; then
- echo "$SHARED_DATA locked, exiting"
+if test -e $TALER_DATA/hier.lock; then
+ echo "$TALER_DATA locked, exiting"
exit 0
fi
# Check if it's writeable.
-if ! test -w $SHARED_DATA; then
- echo "Can't write under $SHARED_DATA, please ajdust permissions"
+if ! test -w $TALER_DATA; then
+ echo "Can't write under $TALER_DATA, please ajdust permissions"
exit 0
fi
# Check if shared-data/ has the right group (test|demo),
# and set the SETGID permission if so.
-SHARED_DATA_GROUP=$(stat -L --format "%G" $SHARED_DATA)
-if ! echo $SHARED_DATA_GROUP | grep -q "^$TALER_CONFIG_ENV$"; then
- echo "$SHARED_DATA has the wrong group ($SHARED_DATA_GROUP), please fix."
+TALER_DATA_GROUP=$(stat -L --format "%G" $TALER_DATA)
+if ! echo $TALER_DATA_GROUP | grep -q "^$TALER_CONFIG_ENV$"; then
+ echo "$TALER_DATA has the wrong group ($TALER_DATA_GROUP), please fix."
exit 1
fi
# Double-check if setgid was set.
-if stat -L --format "%a" $SHARED_DATA | grep -q -v "^[2367][0-9][0-9][0-9]$"; then
- echo "Please make sure $SHARED_DATA has setgid asserted"
+if stat -L --format "%a" $TALER_DATA | grep -q -v "^[2367][0-9][0-9][0-9]$"; then
+ echo "Please make sure $TALER_DATA has setgid asserted"
exit 1
fi
@@ -77,5 +71,5 @@ for dir in ${TALER_DIRS[@]}; do
done
# All dirs will give only the group RWX perms.
-chmod -R 770 $SHARED_DATA/*
-touch $SHARED_DATA/hier.lock
+chmod -R 770 $TALER_DATA/*
+touch $TALER_DATA/hier.lock