-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: avoid errors if Loop is not enabled #1733
Conversation
3af61d6
to
b742479
Compare
should probably also add an if statement for trigger.ts server - https://github.com/GaloyMoney/galoy/blob/main/src/servers/trigger.ts#L409-L412 |
59dcc9f
to
95c1eae
Compare
60f2e0c
to
24fefbc
Compare
24fefbc
to
653cf88
Compare
810a6d7
to
d4dfe0f
Compare
throw new ConfigError("Missing LND1_LOOP_MACAROON config") | ||
if (!process.env.LND2_LOOP_MACAROON) | ||
throw new ConfigError("Missing LND2_LOOP_MACAROON config") | ||
if (getCronConfig().swapEnabled) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be part of service validation
@@ -41,6 +43,9 @@ export const LoopService = ({ | |||
lndInstanceName, | |||
}: LoopdConfig): ISwapService => { | |||
const mac = Buffer.from(macaroon, "base64").toString("hex") as Macaroon | |||
if (!tlsCert) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably here should be the validation, also service should not throw exceptions. Please check onchain service as example
Currently Loop is not running on signet lightninglabs/loop#522 so will needed to keep it off in GaloyMoney/charts#1125.
Fixing the error when deploying on signet with Loop disabled: