nix-bitcoin/modules/modules.nix

59 lines
1.3 KiB
Nix
Raw Normal View History

{ config, pkgs, lib, ... }:
{
imports = [
2020-09-28 10:41:17 +03:00
# Core modules
./secrets/secrets.nix
2020-09-28 14:09:03 +03:00
./operator.nix
2020-09-28 10:41:17 +03:00
# Main features
./bitcoind.nix
./clightning.nix
./lightning-charge.nix
./nanopos.nix
./spark-wallet.nix
./lnd.nix
2020-07-07 17:22:17 +03:00
./lightning-loop.nix
2020-08-12 17:47:56 +03:00
./btcpayserver.nix
2020-09-28 10:41:17 +03:00
./electrs.nix
./liquid.nix
2020-04-23 19:18:47 +03:00
./joinmarket.nix
2020-09-28 10:41:17 +03:00
./hardware-wallets.nix
./recurring-donations.nix
# Support features
./security.nix
./netns-isolation.nix
./backups.nix
./onion-chef.nix
];
disabledModules = [ "services/networking/bitcoind.nix" ];
options = {
nix-bitcoin-services = lib.mkOption {
readOnly = true;
default = import ./nix-bitcoin-services.nix lib pkgs;
};
};
config = {
assertions = [
{ assertion = (config.services.lnd.enable -> ( !config.services.clightning.enable || config.services.clightning.bindport != config.services.lnd.listenPort));
message = ''
LND and clightning can't both bind to lightning port 9735. Either
disable LND/clightning or change services.clightning.bindPort or
services.lnd.listenPort to a port other than 9735.
'';
}
];
nixpkgs.overlays = [ (self: super: {
nix-bitcoin = let
pkgs = import ../pkgs { pkgs = super; };
in
pkgs // pkgs.pinned;
}) ];
};
}