Commit graph

37 commits

Author SHA1 Message Date
bitromortac
dccbf53a17
chanevents: add channel event pruning
We add regular channel event pruning, as otherwise the database may get
filled quickly. We add two mechanisms, a retention time and a max events
number. Both can be turned on individually.
2026-06-25 13:53:26 +02:00
bitromortac
188163c8dd
faraday: initialize stores 2026-04-02 12:25:36 +02:00
Elle Mouton
617c793ec3
multi: update LND, lndclient and btclog deps 2025-03-05 11:51:45 +02:00
Viktor Tigerström
242d5e5c07
Merge pull request #192 from ellemouton/fixMacaroonPathParsing
config+frcli: fix macaroon & tls cert path parsing
2024-08-19 14:37:17 +02:00
Tom Kirkpatrick
da15b558b2
config: add support for signet 2024-08-15 16:47:44 +02:00
Elle Mouton
bd3736d6e2
config: fix parsing of FaradayDir config option
Set the `faradayDirSet` boolean before namespacing the directory with
the network. This fixes a bug where the user would _not_ set faradayDir
but would set the macaroon path and would run into the "faradaydir
overwrites macaroonpath..." error.
2024-08-15 08:52:20 +02:00
Tom Kirkpatrick
59a2d5ee91
config: allow tls cert validity duration to be configured 2024-02-14 15:44:14 +00:00
Oliver Gugger
bb8671250f
config+faraday: allow lnd request timeout to be configured 2024-01-29 10:15:27 +02:00
Oliver Gugger
c80a59758c
multi: bump lnd+lndclient compile time dependency 2023-02-24 19:18:54 +01:00
Oliver Gugger
71bb06f6f7
multi: fix linter issues, run imports 2022-11-21 17:12:17 +01:00
Elle Mouton
8a59081473
multi: use lndclient MacaroonService
Since the code for creating and using a macaroon service is the same for
multiple projects (pool, loop, faraday & litd), the code has been
unified in lndclient. So this commit removes the macaroon service code
and instead uses the lndclient code.

Since the default key for the macaroon db is now a shared secret with
LND, faraday requires LND's admin macaroon so that this secret can be
derived. So this commit also updates all references of LND's `readme`
macaroon to the `admin` macaroon.
2022-06-23 17:26:41 +02:00
positiveblue
d24b4e2557
multi: bump btcec/v2 and btcutil to new versions 2022-03-25 16:55:04 +01:00
Oliver Gugger
83dee8bfe8
config: clean and expand lnd tls cert path
The lncfg.CleanAndExpandPath() call was missing for the lnd TLS
certificate path.
2022-01-19 09:52:28 +01:00
Oliver Gugger
9f9e8a832e
multi: bump lnd compile time dependency to v0.14.0-beta.rc1 2021-11-03 19:24:23 +01:00
Oliver Gugger
a51f229830
multi: move ParseAndSetDebugLevels out of ValidateConfig
We need to move the call that sets all log levels out of the config
validation. Otherwise this will overwrite all subsystem log levels in
LiT where we call the faraday.ValidateConfig() function but have already
set up our loggers.

At the same time we remove the unnecessary global logWriter variable.
2021-05-31 13:57:45 +02:00
Oliver Gugger
4f63e3e1ab
multi: allow only readonly.macaroon to be used
Fixes #84.
Allows faraday to only use the readonly.macaroon (or a custom baked one)
to connect to lnd instead of needing to copy all macaroons (including
the subserver ones).
2021-05-31 13:57:08 +02:00
Oliver Gugger
ddcdda5f43
config: add macaroon path to config 2020-09-11 12:33:25 +02:00
Oliver Gugger
02de78a1a9
config+faraday: extract ValidateConfig
To make it easier to use faraday as an external subserver, it is
necessary to extract the config validation into its own function that is
separate from loading the config.
2020-09-11 12:33:25 +02:00
carla
2be7115ebe
multi: standardize import order 2020-09-09 10:07:14 +02:00
Oliver Gugger
853623e5e4
multi: add TLS config to RPC server
As a preparation to start the gRPC server using TLS, we make sure the
certificate is created and loaded correctly before starting the server
itself.
We also need to silence the linter that complains about the struct
alignment because we didn't put all boolean variables to the beginning.
But since this struct will only be loaded once per process we care more
about similar options being grouped than memory efficiency.
2020-09-08 20:09:30 +02:00
Oliver Gugger
203e597b81
config: add and validate TLS flags 2020-09-08 20:09:30 +02:00
Oliver Gugger
47f8ae10ce
config: add --faradaydir flag
As a preparation to store the TLS certificate and key files, we need a
data directory where faraday stores all its data.
2020-09-08 20:09:23 +02:00
Oliver Gugger
74b7af0d6b
config: use just one network flag
To make the command line interface a bit more similar to other tools
like loop, we switch from using single flags like --testnet or --regtest
to just one --network flag.
2020-09-08 19:48:24 +02:00
Oliver Gugger
a7166ad836
config: move lnd parameter into sub struct
As a preparation to add TLS to faraday itself, we need to move the
parameters that are meant for lnd into its own sub struct to avoid name
collisions and user confusion.
2020-09-08 19:48:23 +02:00
carla
3f9d798ea0
config: add version flag 2020-08-11 10:07:16 +02:00
carla
bb0b82aaee
multi: optionally connect faraday to a bitcoin node
Original chain code copied from:
e3c34449484d7dc8d505a98ea275e510651d7c3d

Co-authored-by: Oliver Gugger gugger@gmail.com
2020-06-27 14:47:20 +02:00
carla
03077bcae3
multi: connect faraday to lnd services rather than lnd client
We are going to need the walletkit and chainnotifier subservers in
future changes, so we make the switch now. Note that this commit does
not build, and is split up for the sake of easy review.
2020-06-17 09:42:55 +02:00
Oliver Gugger
c924402d15
config: expose Config struct 2020-05-14 15:00:08 +02:00
Oliver Gugger
a09f5edfec
faraday+config: expose LoadConfig and DefaultConfig 2020-05-14 14:59:16 +02:00
Oliver Gugger
18a88b76ee
config: add RESTListen and CORSOrigin options 2020-04-07 11:12:38 +02:00
carla
df836c2d21
multi: faraday rename 2020-03-30 09:25:46 +02:00
carla
5c28058d4a
config: update default port to 8465
Update default port to 8465 which has no commonly used TCP application
to avoid collisions.
2020-03-10 11:02:35 +02:00
carla
36dfb58c37
multi: rename terminator main package to governator 2020-03-05 17:07:21 +02:00
carla
a3cdc4bdb6
multi: add terminator grpc server 2020-01-31 13:20:09 +02:00
carla
466f46fbab
terminator: make debug level configurable 2019-12-19 15:45:38 +02:00
carla
b4614f9550
terminator: query for recommendations on startup 2019-12-19 15:45:38 +02:00
carla
e91b22480f terminator: Connect to LND RPC
This commit adds code to connect to LND's RPC from the
terminator main function. It allows users to specify
config through command line flags, and validates the
input where possible.
2019-11-04 10:39:33 +02:00