commit 1f46dda63333edf16b2c0dfc9f3b4cce30f2c7a9
parent 7e851ec5e6f21a41d605ec919a26865a6081bfd8
Author: Christian Grothoff <christian@grothoff.org>
Date: Sat, 13 Jan 2024 21:23:30 +0100
allow global auth spec
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/contrib/taler-mdb-network-check.sh b/contrib/taler-mdb-network-check.sh
@@ -112,6 +112,7 @@ function check_network()
{
DEF_BACKEND=$(taler-config -c "$CONF" -s "taler-mdb" -o "BACKEND_BASE_URL")
BACKEND_HOSTNAME=$(echo "$DEF_BACKEND" | awk -F/ '{print $3}')
+ BACKEND_AUTH=$(taler-config -c "$CONF" -s "taler-mdb" -o "BACKEND_AUTHORIZATION")
DNS_HOST=$(grep nameserver /etc/resolv.conf | grep -v '^#' | head -n1 | awk '{print $2}')
if ! ping -c1 "$DNS_HOST" &> /dev/null
@@ -149,7 +150,7 @@ function check_network()
for PS in $(taler-config -c "$CONF" -S | grep "product-" | head -n1)
do
URL=$(taler-config -c "$CONF" -s "$PS" -o "INSTANCE" 2> /dev/null || echo "$DEF_BACKEND")
- AUTH=$(taler-config -c "$CONF" -s "$PS" -o "BACKEND_AUTHORIZATION")
+ AUTH=$(taler-config -c "$CONF" -s "$PS" -o "BACKEND_AUTHORIZATION" 2> /dev/null || echo "$BACKEND_AUTH")
if ! wget --header "Authorization: $AUTH" "${URL}private/orders" -O /dev/null &> /dev/null
then