summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntoine A <>2024-04-03 00:40:06 +0200
committerAntoine A <>2024-04-03 00:40:06 +0200
commit6f4eea38dee9a81d586cb3e5ca2226d83999dc70 (patch)
tree62a7d77d3a47499d0d9b71619fa9de1a0f506456
parent534f2e58e4e46a4689bb6af5291452344c44b9fd (diff)
downloaddeployment-6f4eea38dee9a81d586cb3e5ca2226d83999dc70.tar.gz
deployment-6f4eea38dee9a81d586cb3e5ca2226d83999dc70.tar.bz2
deployment-6f4eea38dee9a81d586cb3e5ca2226d83999dc70.zip
regio: fix reconfiguration
-rwxr-xr-xregional-currency/setup-exchange.sh6
-rwxr-xr-xregional-currency/setup-libeufin.sh7
2 files changed, 3 insertions, 10 deletions
diff --git a/regional-currency/setup-exchange.sh b/regional-currency/setup-exchange.sh
index c14adfc..1f0b49d 100755
--- a/regional-currency/setup-exchange.sh
+++ b/regional-currency/setup-exchange.sh
@@ -42,10 +42,6 @@ if test -z "${BANK_EXCHANGE_PASSWORD:-}"; then
say "Failure: BANK_EXCHANGE_PASSWORD not set"
exit 1
fi
-if test -z "${EXCHANGE_WIRE_GATEWAY_URL:-}"; then
- say "Failure: EXCHANGE_WIRE_GATEWAY_URL not set"
- exit 1
-fi
if test -z "${EXCHANGE_PAYTO:-}"; then
say "Failure: EXCHANGE_PAYTO not set"
exit 1
@@ -169,7 +165,7 @@ chown root:taler-exchange-db /etc/taler/secrets/exchange-db.secret.conf
cat << EOF > /etc/taler/secrets/exchange-accountcredentials-default.secret.conf
[exchange-accountcredentials-default]
-WIRE_GATEWAY_URL=${EXCHANGE_WIRE_GATEWAY_URL}
+WIRE_GATEWAY_URL=${PROTO}://bank.$DOMAIN_NAME/accounts/exchange/taler-wire-gateway/
WIRE_GATEWAY_AUTH_METHOD=basic
USERNAME=exchange
PASSWORD=${BANK_EXCHANGE_PASSWORD}
diff --git a/regional-currency/setup-libeufin.sh b/regional-currency/setup-libeufin.sh
index efbd714..ff64d6c 100755
--- a/regional-currency/setup-libeufin.sh
+++ b/regional-currency/setup-libeufin.sh
@@ -95,14 +95,11 @@ echo "settings = { bankName: \"${BANK_NAME}\" }" >/etc/libeufin/settings.js
say "Create exchange account..."
if test -z "${EXCHANGE_PAYTO:-}"; then
+ # FIXME create-account should have a way to update the password if the account already exists
EXCHANGE_PAYTO_NEW="$(sudo -u libeufin-bank libeufin-bank create-account -c /etc/libeufin/libeufin-bank.conf --username exchange --password "${BANK_EXCHANGE_PASSWORD}" --name Exchange --exchange 2>> setup.log)?receiver-name=Exchange"
- echo "EXCHANGE_PAYTO=\"${EXCHANGE_PAYTO_NEW}\"" >> config/internal.conf
+ echo "EXCHANGE_PAYTO=\"${EXCHANGE_PAYTO_NEW}\"" >> config/user.conf
fi
-if test -z "${EXCHANGE_WIRE_GATEWAY_URL:-}"; then
- EXCHANGE_WIRE_GATEWAY_URL_NEW="${PROTO}://bank.$DOMAIN_NAME/accounts/exchange/taler-wire-gateway/"
- echo "EXCHANGE_WIRE_GATEWAY_URL=\"${EXCHANGE_WIRE_GATEWAY_URL_NEW}\"" >> config/internal.conf
-fi
say "Start the bank..."
systemctl enable libeufin-bank &>> setup.log