clightning: add netns

- Adds clightning to netns-isolation.services
- Adds bitcoin-rpcconnect option to allow using clightning with network
  namespaces
- Uses bind-addr option (defaults to localhost) as target of hidden service
- Adds different bind-addr options depending on if netns-isolation is
  enabled or not.
This commit is contained in:
nixbitcoin
2020-06-10 14:31:38 +00:00
parent ae1230e13b
commit 3c0c446547
3 changed files with 19 additions and 2 deletions

View File

@@ -78,9 +78,8 @@ in {
proxy = cfg.tor.client.socksListenAddress;
enforceTor = true;
always-use-proxy = true;
bind-addr = "127.0.0.1:${toString cfg.clightning.onionport}";
};
services.tor.hiddenServices.clightning = mkHiddenService { port = cfg.clightning.onionport; };
services.tor.hiddenServices.clightning = mkHiddenService { port = cfg.clightning.onionport; toHost = (builtins.head (builtins.split ":" cfg.clightning.bind-addr)); };
# lnd
services.lnd.enforceTor = true;