services: use new 'tor' options

This commit is contained in:
Erik Arvstedt
2021-08-05 00:49:00 +02:00
parent e44f78ebb8
commit 178a0dcf8f
18 changed files with 56 additions and 39 deletions

View File

@@ -95,12 +95,12 @@ let
'';
mkIfOnionPort = name: fn:
if hiddenServices ? ${name} then
fn (toString (builtins.elemAt hiddenServices.${name}.map 0).port)
if onionServices ? ${name} then
fn (toString (builtins.elemAt onionServices.${name}.map 0).port)
else
"";
inherit (config.services.tor) hiddenServices;
inherit (config.services.tor.relay) onionServices;
in {
options = {
nix-bitcoin.nodeinfo = {