-
Notifications
You must be signed in to change notification settings - Fork 45
/
complex-ruleset.config
139 lines (113 loc) · 4.43 KB
/
complex-ruleset.config
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
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
[default]
# 'default' is special, it is used if no other policy matches a channel
strategy = static
base_fee_msat = 1_000
fee_ppm = 10
inbound_base_fee_msat = -500
inbound_fee_ppm = -5
[mydefaults]
# no strategy, so this only sets some defaults
base_fee_msat = 1_000
min_fee_ppm_delta = 5
[zerobasefee-initiative]
# set base_fee_msat default to 0 if peer sets zero base fees
chan.max_base_fee_msat = 0
base_fee_msat = 0
[onchain-congestion]
# if the onchain fee rate is high (>= 500 sat/vbyte) we increase the base fee to 5 sat
onchan.min_fee_rate = 500
base_fee_msat = 5_000
[lost-onchain-sync]
# The fact that lnd was not synchronized with the chain for more than 5 minutes
# was an indicator of a severe problem in the past.
onchain.synced_to_chain = false
base_fee_msat = 210_000
fee_ppm = 210_000
[ignored_channels]
# don't let charge-lnd set fees (strategy=ignore) for channels to/from the specified nodes
node.id = 02da8d5a759ee9e4438da617cfdb61c87f723fb76c4b6371b877d0347abe953a4f,
0266ad254117f16f16c3457e081e6207e91c5e414477a208cf4d9c633322799038
strategy = ignore
[known-one-way-drains]
node.id = 033d8656219478701227199cbd6f670335c8d408a92ae88b962c49d4dc0e83e025,
03cde60a6323f7122d5178255766e38114b4722ede08f7c9e0c5df9b912cc201d6
021c97a90a411ff2b10dc2a8e32de2f29d2fa49d41bfbb52bd416e460db0747d0d,
03037dc08e9ac63b82581f79b662a4d0ceca8a8ca162b1af3551595b8f2d97b70a,
030c3f19d742ca294a55c00376b3b355c3c90d61c6b6b39554dbc7ac19b141c14f,
03d607f3e69fd032524a867b288216bfab263b6eaee4e07783799a6fe69bb84fac,
02a04446caa81636d60d63b066f2814cbd3a6b5c258e3172cbdded7a16e2cfff4c
strategy = static
fee_ppm = 3500
[expensive]
# match channels where the peer node has set a high (>=8_000 ppm) fee rate
# and set the same fee rate on our side (strategy=match_peer)
chan.min_fee_ppm = 8_000
strategy = match_peer
[leafnode]
# charge non-routing (private=true) peers a bit more for our service
chan.private = true
strategy = static
fee_ppm = 100
[beginner-node]
# set lower fees on channels with smaller peers, that have few channels (4-8 channels) total
# and limited node size (max_capacity=1_000_000)
node.max_capacity = 1_000_000
node.min_channels = 4
node.max_channels = 8
strategy = static
base_fee_msat = 0
fee_ppm = 1
[encourage-routing]
# 'autobalance' (lower fees so using outbound is more attractive) larger channels (min_capacity 2M sats)
# to larger nodes (node has at least 50M sats) if balance ratio >= 0.9 (more than 90% on our side)
chan.min_ratio = 0.9
chan.min_capacity = 2_000_000
node.min_capacity = 5_000_0000
strategy = static
base_fee_msat = 500
fee_ppm = 5
[discourage-routing]
# 'autobalance' (higher fees so using outbound is less attractive) larger channels (min_capacity 2M sats)
# to larger nodes (node has at least 50M sats) if balance ratio <= 0.2 (less than 20% on our side)
chan.max_ratio = 0.2
chan.min_capacity = 2_000_000
node.min_capacity = 5_000_0000
strategy = static
base_fee_msat = 10_000
fee_ppm = 500
[proportional]
# 'proportional' can also be used to auto balance (lower fee rate when low remote balance & higher rate when higher remote balance)
# fee_ppm decreases linearly with the channel balance ratio (min_fee_ppm when ratio is 1, max_fee_ppm when ratio is 0)
chan.min_ratio = 0.2
chan.max_ratio = 0.9
chan.min_capacity = 1_000_000
strategy = proportional
min_fee_ppm = 10
max_fee_ppm = 200
[pool-policy]
# use a list of channels exported from Lightning Pool to set a policy for channels that we initiated by selling liquidity using Lightning Pool
chan.id = file:///home/lnd/pool-channels.txt
strategy = static
base_fee_msat = 500
fee_ppm = 1
[recover-cost]
# use cost strategy if we are the initiator, using a base fee of 1 sat, and a cost_factor of 1.5 to recover 150% of costs when
# channel is depleted to 100% outgoing
chan.initiator = true
strategy = cost
cost_factor = 1.5
#[on-chain-competitive]
# (commented out this policy as it doesn't work without setting --electrum-server command line option and we want this example to be be able to be used as-is)
# If an on-chain TX of 0.1 BTC within 6 blocks would amount to a 0.0001 fee (=0.1%), this policy sets the channel fee to 0.1% (or 1000 ppm)
#node.id = 03864ef025fde8fb587d989186ce6a4a186895ee44a926bfc370e2c366597a3f8f
#strategy = onchain_fee
#base_fee_msat = 1_000
#onchain_fee_btc = 0.1
#onchain_fee_numblocks = 6
[micropayments-only]
# set max_htlc_msat to 1_000 sat (1M msat)
chan.id = 636374x680x1
strategy = static
base_fee_msat = 1_000
fee_ppm = 10
max_htlc_msat = 1_000_000