libeufin

Integration and sandbox testing for FinTech APIs and data formats
Log | Files | Refs | Submodules | README | LICENSE

commit 2f4ac08b02f763a941d1ee0154ff6e2ed5b9c024
parent cbdb013d76bf404930055eabc85165a870318a3a
Author: Antoine A <>
Date:   Tue,  6 Feb 2024 15:10:38 +0100

Use libeufin-nexus-postgres for libeufin-nexus db config

Diffstat:
Mcontrib/nexus.conf | 7++++---
Mnexus/conf/test.conf | 2+-
Mnexus/src/main/kotlin/tech/libeufin/nexus/Main.kt | 2+-
Mtestbench/conf/integration.conf | 2+-
Mtestbench/conf/mini.conf | 3+++
Mtestbench/src/main/kotlin/Main.kt | 2+-
6 files changed, 11 insertions(+), 7 deletions(-)

diff --git a/contrib/nexus.conf b/contrib/nexus.conf @@ -35,12 +35,13 @@ CLIENT_PRIVATE_KEYS_FILE = ${LIBEUFIN_NEXUS_HOME}/client-ebics-keys.json # Typically, it is named after the bank itself. BANK_DIALECT = postfinance -[nexus-postgres] -CONFIG = postgres:///libeufin - [libeufin-nexusdb-postgres] +# Where are the SQL files to setup our tables? SQL_DIR = $DATADIR/sql/ +# DB connection string +CONFIG = postgres:///libeufin + [nexus-fetch] FREQUENCY = 30m diff --git a/nexus/conf/test.conf b/nexus/conf/test.conf @@ -9,5 +9,5 @@ HOST_ID = PFEBICS USER_ID = PFC00563 PARTNER_ID = PFC00563 -[nexus-postgres] +[libeufin-nexusdb-postgres] CONFIG = postgres:///libeufincheck \ No newline at end of file diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt @@ -209,7 +209,7 @@ fun loadConfig(configFile: Path?): TalerConfig = NEXUS_CONFIG_SOURCE.fromFile(co */ fun TalerConfig.dbConfig(): DatabaseConfig = DatabaseConfig( - dbConnStr = requireString("nexus-postgres", "config"), + dbConnStr = lookupString("libeufin-nexusdb-postgres", "config") ?: requireString("nexus-postgres", "config"), sqlDir = requirePath("libeufin-nexusdb-postgres", "sql_dir") ) diff --git a/testbench/conf/integration.conf b/testbench/conf/integration.conf @@ -13,5 +13,5 @@ CONFIG = postgresql:///libeufincheck [nexus-ebics] currency = EUR -[nexus-postgres] +[libeufin-bankdb-postgres] CONFIG = postgres:///libeufincheck diff --git a/testbench/conf/mini.conf b/testbench/conf/mini.conf @@ -1,2 +1,5 @@ [libeufin-bankdb-postgres] +CONFIG = postgresql:///libeufincheck + +[libeufin-nexusdb-postgres] CONFIG = postgresql:///libeufincheck \ No newline at end of file diff --git a/testbench/src/main/kotlin/Main.kt b/testbench/src/main/kotlin/Main.kt @@ -92,7 +92,7 @@ class Cli : CliktCommand("Run integration tests on banks provider") { [nexus-submit] FREQUENCY = 5s - [nexus-postgres] + [libeufin-nexusdb-postgres] CONFIG = postgres:///libeufincheck """) val cfg = loadConfig(conf)