nixos/libeufin: update BASE_URL

which is now required to have a valid protocol.
This commit is contained in:
eljamm 2025-05-29 11:10:14 +02:00 committed by Valentin Gagarin
parent 276fca3265
commit e04f8bb993
3 changed files with 4 additions and 3 deletions

View file

@ -35,6 +35,7 @@ libeufinComponent:
cfg.settings."libeufin-${libeufinComponent}db-postgres".CONFIG;
bankPort = cfg.settings."${if isNexus then "nexus-httpd" else "libeufin-bank"}".PORT;
bankHost = lib.elemAt (lib.splitString "/" cfg.settings.libeufin-bank.BASE_URL) 2;
in
lib.mkIf cfg.enable {
services.libeufin.settings = cfg.settings;
@ -82,7 +83,7 @@ libeufinComponent:
args = lib.cli.toGNUCommandLineShell { } {
c = configFile;
inherit (account) username password name;
payto_uri = "payto://x-taler-bank/bank:${toString bankPort}/${account.username}?receiver-name=${account.name}";
payto_uri = "payto://x-taler-bank/${bankHost}/${account.username}?receiver-name=${account.name}";
exchange = lib.toLower account.username == "exchange";
};
in

View file

@ -103,7 +103,7 @@ rec {
# WIRE_TYPE = "iban";
X_TALER_BANK_PAYTO_HOSTNAME = "bank:8082";
# IBAN_PAYTO_BIC = "SANDBOXX";
BASE_URL = "bank:8082";
BASE_URL = "http://bank:8082/";
# Allow creating new accounts
ALLOW_REGISTRATION = "yes";

View file

@ -7,7 +7,7 @@
let
cfgNodes = pkgs.callPackage ./nodes.nix { inherit lib; };
bankConfig = nodes.bank.config.environment.etc."libeufin/libeufin.conf".source;
bankConfig = nodes.bank.environment.etc."libeufin/libeufin.conf".source;
inherit (cfgNodes) CURRENCY FIAT_CURRENCY;
in