nanopos: add netns
- Adds nanopos to netns-isolation.services - Adds cfg.enforceTor and extraArgs to bring nanopos in line with other services - Adds charged-url option to allow using nanopos with network namespaces. - Modularizes nginx so webindex can be used without nanopos. - Adds host option (defaults to localhost) as target of hidden service - Removes unnecessary after
This commit is contained in:
@@ -115,6 +115,10 @@ in {
|
||||
# communicates with clightning over lightning-rpc socket
|
||||
connections = [];
|
||||
};
|
||||
nanopos = {
|
||||
id = 19;
|
||||
connections = [ "nginx" "lightning-charge" ];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services = {
|
||||
@@ -271,6 +275,12 @@ in {
|
||||
# lightning-charge: Custom netns configs
|
||||
services.lightning-charge.host = mkIf config.services.lightning-charge.enable netns.lightning-charge.address;
|
||||
|
||||
# nanopos: Custom netns configs
|
||||
services.nanopos = mkIf config.services.nanopos.enable {
|
||||
charged-url = "http://${netns.lightning-charge.address}:9112";
|
||||
host = netns.nanopos.address;
|
||||
};
|
||||
|
||||
})
|
||||
# Custom netns config option values if netns-isolation not enabled
|
||||
(mkIf (!cfg.enable) {
|
||||
|
||||
Reference in New Issue
Block a user