[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-deployment] branch master updated: reduce global config values
From: |
gnunet |
Subject: |
[taler-deployment] branch master updated: reduce global config values |
Date: |
Thu, 13 Oct 2022 12:58:43 +0200 |
This is an automated email from the git hooks/post-receive script.
ms pushed a commit to branch master
in repository deployment.
The following commit(s) were added to refs/heads/master by this push:
new ee67a91 reduce global config values
ee67a91 is described below
commit ee67a917a5fc80d47371fa6004e240820fd99ea3
Author: MS <ms@taler.net>
AuthorDate: Thu Oct 13 12:58:36 2022 +0200
reduce global config values
---
docker/hybrid/config/deployment.conf | 16 ----------------
docker/hybrid/docker-compose.yml | 2 ++
docker/hybrid/images/exchange/startup.sh | 2 +-
docker/hybrid/images/libeufin/startup.sh | 11 +++++++----
docker/hybrid/images/merchant/startup.sh | 6 +++---
5 files changed, 13 insertions(+), 24 deletions(-)
diff --git a/docker/hybrid/config/deployment.conf
b/docker/hybrid/config/deployment.conf
index 4a9383e..4475587 100644
--- a/docker/hybrid/config/deployment.conf
+++ b/docker/hybrid/config/deployment.conf
@@ -1,18 +1,2 @@
-# In this setup, there are 3 different network views:
-#
-# 1, host's loopback
-# 2, containers LAN
-# 3, every single container's loopback
-
[taler-deployment]
currency = EUR
-
-# The following URL belongs only to 2, resulting
-# in the wallet NOT being able to use it.
-exchange_base_url = http://exchange/
-
-# The following URL belongs to 1 and 3, resulting
-# in any other service _not_ running in the exchange
-# container being unable to reach the exchange (
-# without an artificial bridge).
-# exchange_base_url = http://localhost:5555/
diff --git a/docker/hybrid/docker-compose.yml b/docker/hybrid/docker-compose.yml
index 3764172..27b5ab1 100644
--- a/docker/hybrid/docker-compose.yml
+++ b/docker/hybrid/docker-compose.yml
@@ -31,3 +31,5 @@ services:
ports:
- 15000:15000 # Sandbox
- 15001:15001 # Nexus
+ volumes:
+ - ${TALER_DEPLOYMENT_CONFIG}:/config/deployment.conf
diff --git a/docker/hybrid/images/exchange/startup.sh
b/docker/hybrid/images/exchange/startup.sh
index 3515191..1c6ea9f 100644
--- a/docker/hybrid/images/exchange/startup.sh
+++ b/docker/hybrid/images/exchange/startup.sh
@@ -5,7 +5,7 @@ export LD_LIBRARY_PATH=/usr/local/lib
# Values from config file mounted at run time:
CURRENCY=`taler-config -c /config/deployment.conf -s taler-deployment -o
currency`
-EXCHANGE_URL=`taler-config -c /config/deployment.conf -s taler-deployment -o
exchange_base_url`
+EXCHANGE_URL="http://exchange/"
EXCHANGE_NEXUS_USERNAME=exchange-at-nexus
EXCHANGE_NEXUS_PASSWORD=x
diff --git a/docker/hybrid/images/libeufin/startup.sh
b/docker/hybrid/images/libeufin/startup.sh
index 609a09b..6bd9c1f 100644
--- a/docker/hybrid/images/libeufin/startup.sh
+++ b/docker/hybrid/images/libeufin/startup.sh
@@ -2,9 +2,12 @@
set -eu
+export LD_LIBRARY_PATH=/usr/local/lib # helps taler-config
+CURRENCY=`taler-config -c /config/deployment.conf -s taler-deployment -o
currency`
SANDBOX_PORT=15000
NEXUS_PORT=15001
SANDBOX_BASE_URL="http://localhost:${SANDBOX_PORT}"
+EXCHANGE_URL="http://exchange/"
# As wanted by the Libeufin CLI:
export LIBEUFIN_SANDBOX_URL="${SANDBOX_BASE_URL}/demobanks/default"
export LIBEUFIN_NEXUS_URL="http://localhost:${NEXUS_PORT}"
@@ -41,12 +44,12 @@ EXCHANGE_IBAN=DE159593
export LIBEUFIN_SANDBOX_DB_CONNECTION="jdbc:sqlite:/libeufin.sqlite3"
export LIBEUFIN_SANDBOX_ADMIN_PASSWORD=secret
-echo -n "Creating EUR default demobank..."
-libeufin-sandbox config --currency EUR default
+echo -n "Creating ${CURRENCY} default demobank..."
+libeufin-sandbox config --currency ${CURRENCY} default
echo DONE
echo -n "Specify default exchange..."
libeufin-sandbox default-exchange \
- http://localhost:5555/ \
+ ${EXCHANGE_URL} \
"payto://iban/SANDBOXX/${EXCHANGE_IBAN}?receiver-name=Exchange+Company"
echo DONE
echo -n "Launching Sandbox..."
@@ -129,7 +132,7 @@ echo -n Create the Taler facade at Nexus..
FACADE_NAME=taler-facade
libeufin-cli facades \
new-taler-wire-gateway-facade \
- --currency EUR --facade-name $FACADE_NAME \
+ --currency ${CURRENCY} --facade-name $FACADE_NAME \
talerconn $NEXUS_IMPORTED_BANKACCOUNT
echo DONE
diff --git a/docker/hybrid/images/merchant/startup.sh
b/docker/hybrid/images/merchant/startup.sh
index 507f2ea..83c4db0 100644
--- a/docker/hybrid/images/merchant/startup.sh
+++ b/docker/hybrid/images/merchant/startup.sh
@@ -4,8 +4,8 @@ set -eu
export LD_LIBRARY_PATH=/usr/local/lib
# Values from config file mounted at run time:
-EXCHANGE_URL=`taler-config -c /config/deployment.conf -s taler-deployment -o
exchange_base_url`
CURRENCY=`taler-config -c /config/deployment.conf -s taler-deployment -o
currency`
+EXCHANGE_URL="http://exchange/"
while ! pg_isready -h talerdb -d taler; do
echo DB not ready yet.
@@ -52,10 +52,10 @@ taler-merchant-httpd -c /config/taler.conf &
echo DONE
sleep 1
echo -n "Create default instance..."
-curl -s -H "Content-Type: application/json" -X POST -d
'{"auth":{"method":"external"},"payto_uris":["payto://iban/SANDBOXX/DE474361?receiver-name=Merchant43"],"id":"default","name":"default","address":{},"jurisdiction":{},"default_max_wire_fee":"EUR:1",
"default_max_deposit_fee":"EUR:1","default_wire_fee_amortization":1,"default_wire_transfer_delay":{"d_us"
: 3600000000},"default_pay_delay":{"d_us": 3600000000}}'
http://merchant/management/instances
+curl -s -H "Content-Type: application/json" -X POST -d
'{"auth":{"method":"external"},"payto_uris":["payto://iban/SANDBOXX/DE474361?receiver-name=Merchant43"],"id":"default","name":"default","address":{},"jurisdiction":{},"default_max_wire_fee":"'${CURRENCY}':1",
"default_max_deposit_fee":"'${CURRENCY}':1","default_wire_fee_amortization":1,"default_wire_transfer_delay":{"d_us"
: 3600000000},"default_pay_delay":{"d_us": 3600000000}}'
http://merchant/management/instances
echo DONE
-# FIXME: the command below works around a known bug,
+# FIXME: the command below works around a bug,
# where demo sites ingnore the "-c" option.
# mkdir ${HOME}/.config/
# ln -s /config/taler.conf ${HOME}/.config/
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [taler-deployment] branch master updated: reduce global config values,
gnunet <=