-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathconfiguration.nix
110 lines (93 loc) · 2.43 KB
/
configuration.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
flakeInputs:
{ config, pkgs, lib, ... }:
{
imports = [
flakeInputs.nix-bitcoin.nixosModules.default
(flakeInputs.nix-bitcoin + "/modules/presets/secure-node.nix")
flakeInputs.nixos-mailserver.outPath
./base.nix
./website
./matrix.nix
./backup.nix
];
services.bitcoind = {
i2p = true;
tor.enforce = false;
tor.proxy = false;
rpc.threads = lib.mkForce 20;
extraConfig = ''
mempoolfullrbf=1
rpcworkqueue=32
'';
};
nix-bitcoin.onionServices.bitcoind.public = true;
services.clightning = {
enable = true;
tor.enforce = false;
tor.proxy = false;
plugins.clboss.enable = true;
extraConfig = ''
alias=nixbitcoin.org
'';
};
nix-bitcoin.onionServices.clightning.public = true;
systemd.services.clightning.serviceConfig.TimeoutStartSec = "5m";
services.rtl = {
enable = true;
nodes.clightning.enable = true;
};
services.btcpayserver = {
enable = true;
lightningBackend = "clightning";
lbtc = true;
};
nix-bitcoin.onionServices.btcpayserver.enable = true;
# Don't require `liquidd.service` so that btcp can stay online while liquidd is
# shutting down/restarting, which can take up to 30 min.
systemd.services.nbxplorer = rec {
requires = lib.mkForce [ "bitcoind.service" "postgresql.service" ];
after = requires;
};
services.joinmarket = {
enable = true;
yieldgenerator.enable = true;
};
services.joinmarket-ob-watcher.enable = true;
# ob-watcher gets buggy after running for a while, so periodically restart
systemd.services.joinmarket-ob-watcher = rec {
serviceConfig = {
Restart = lib.mkForce "always";
RuntimeMaxSec = "1 week";
};
};
services.electrs.enable = true;
services.fulcrum = {
enable = true;
port = 50011;
};
services.mempool = {
enable = true;
electrumServer = "fulcrum";
tor = {
proxy = true;
enforce = true;
};
};
nix-bitcoin.onionServices.mempool-frontend.enable = true;
nixbitcoin-org.website = {
enable = true;
donate.btcpayserverAppId = "3NKhG5wANegkfmXJ5x4ZNuSAB1z5";
};
nix-bitcoin.netns-isolation.enable = true;
programs.extra-container.enable = true;
services.postgresql.enableJIT = true;
services.zfs.autoScrub = {
enable = true;
interval = "monthly";
};
environment.variables = {
# Use 24h time format
LC_TIME = "C.UTF-8";
};
nix-bitcoin.configVersion = "0.0.85";
}