spark-wallet: add consistent address options
This commit is contained in:
parent
39f16c0b4a
commit
09e0042aa8
@ -274,7 +274,7 @@ in {
|
|||||||
services.electrs.address = netns.electrs.address;
|
services.electrs.address = netns.electrs.address;
|
||||||
|
|
||||||
services.spark-wallet = {
|
services.spark-wallet = {
|
||||||
host = netns.spark-wallet.address;
|
address = netns.spark-wallet.address;
|
||||||
extraArgs = "--no-tls";
|
extraArgs = "--no-tls";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@ let
|
|||||||
''}
|
''}
|
||||||
exec ${config.nix-bitcoin.pkgs.spark-wallet}/bin/spark-wallet \
|
exec ${config.nix-bitcoin.pkgs.spark-wallet}/bin/spark-wallet \
|
||||||
--ln-path '${config.services.clightning.networkDir}' \
|
--ln-path '${config.services.clightning.networkDir}' \
|
||||||
--host ${cfg.host} \
|
--host ${cfg.address} --port ${toString cfg.port} \
|
||||||
--config '${config.nix-bitcoin.secretsDir}/spark-wallet-login' \
|
--config '${config.nix-bitcoin.secretsDir}/spark-wallet-login' \
|
||||||
${optionalString cfg.enforceTor torRateProvider} \
|
${optionalString cfg.enforceTor torRateProvider} \
|
||||||
$publicURL \
|
$publicURL \
|
||||||
@ -31,10 +31,15 @@ in {
|
|||||||
If enabled, the spark-wallet service will be installed.
|
If enabled, the spark-wallet service will be installed.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
host = mkOption {
|
address = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
default = "localhost";
|
default = "localhost";
|
||||||
description = "http(s) server listen address.";
|
description = "http(s) server address.";
|
||||||
|
};
|
||||||
|
port = mkOption {
|
||||||
|
type = types.port;
|
||||||
|
default = 9737;
|
||||||
|
description = "http(s) server port.";
|
||||||
};
|
};
|
||||||
onion-service = mkOption {
|
onion-service = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
@ -63,7 +68,7 @@ in {
|
|||||||
|
|
||||||
services.tor.hiddenServices.spark-wallet = mkIf cfg.onion-service {
|
services.tor.hiddenServices.spark-wallet = mkIf cfg.onion-service {
|
||||||
map = [{
|
map = [{
|
||||||
port = 80; toPort = 9737; toHost = cfg.host;
|
port = 80; toPort = cfg.port; toHost = cfg.address;
|
||||||
}];
|
}];
|
||||||
version = 3;
|
version = 3;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user