mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-21 14:24:09 +01:00
pyln: Set the bitcoin datadir when running tests
Telling `lightningd` to pass a `-datadir` to `bitcoin-cli` so it doesn't go snooping where it doesn't belong (i.e., the user's home directory and config). Changelog-None Suggested-by: Simon Vrouwe <@SimonVrouwe> Signed-off-by: Christian Decker <@cdecker>
This commit is contained in:
parent
9bfdf234f3
commit
7b752e00d5
2 changed files with 4 additions and 0 deletions
|
@ -489,6 +489,9 @@ class LightningD(TailableProc):
|
|||
'ignore-fee-limits': 'false',
|
||||
'bitcoin-rpcuser': BITCOIND_CONFIG['rpcuser'],
|
||||
'bitcoin-rpcpassword': BITCOIND_CONFIG['rpcpassword'],
|
||||
|
||||
# Make sure we don't touch any existing config files in the user's $HOME
|
||||
'bitcoin-datadir': lightning_dir,
|
||||
}
|
||||
|
||||
for k, v in opts.items():
|
||||
|
|
|
@ -33,5 +33,6 @@ def getchaininfo(plugin, **kwargs):
|
|||
plugin.add_option("bitcoin-rpcuser", "", "")
|
||||
plugin.add_option("bitcoin-rpcpassword", "", "")
|
||||
plugin.add_option("bitcoin-rpcport", "", "")
|
||||
plugin.add_option("bitcoin-datadir", "", "")
|
||||
|
||||
plugin.run()
|
||||
|
|
Loading…
Add table
Reference in a new issue