getumbrel / umbrel

A beautiful home server OS for self-hosting with an app store. Buy a pre-built Umbrel Home with umbrelOS, or install on a Raspberry Pi or any x86 system.
https://umbrel.com
Other
7.32k stars 527 forks source link

[Ride the Lightning] ERROR: empty macaroon data #443

Closed jonnylangefeld closed 3 years ago

jonnylangefeld commented 3 years ago

I installed ride-the-lightning (RTL) via the app store and wanted to try out the loop feature. Under lightning -> loop I saw the following error: Screen Shot 2021-01-19 at 9 40 15 PM After a bit of investigation I found out that RTL needs a node.authentication key in the RTL-Config.json file. However, after exec'ing into the ride-the-lightning_web_1 docker container, I saw that this key isn't there:

docker exec -it ride-the-lightning_web_1 sh
/RTL $ cat /data/RTL-Config.json
{
  "defaultNodeIndex": 1,
  "SSO": {
    "rtlSSO": 0,
    "rtlCookiePath": "",
    "logoutRedirectLink": ""
  },
  "nodes": [
    {
      "index": 1,
      "lnNode": "Umbrel",
      "Settings": {
        "userPersona": "MERCHANT",
        "themeMode": "DAY",
        "themeColor": "PURPLE",
        "enableLogging": true,
        "fiatConversion": true
      }
    }
  ],
  "multiPassHashed": "<truncated>"
}

According to the RTL readme it sounds like the node.authentication key should look something like this:

    "Authentication": {
        "macaroonPath": "<Complete path of the folder containing admin.macaroon for the node # 1>",
        "swapMacaroonPath": "<Complete path of the folder containing loop.macaroon for the node # 1>"
      }

I found the admin.macaroon file under this path inside the RTL web container: /lnd/data/chain/bitcoin/testnet/admin.macaroon. But the loop.macaroon file was nowhere to be found. It looks like the docker-compose file for the app is supposed to configure the swapMacaroonPath here. The path there ultimately resolves to this path of the repository, and there is no loops direcotry.

Hope this analysis helps to quickly resolve the error about missing macaroon data!

louneskmt commented 3 years ago

Hey! Thanks for reporting this. We use environment variables to config RTL so it's normal the keys you found are not visible in the config file.

In fact, I just checked the configuration and I've set the wrong path for the Loop macaroon.

I will do some testing and this will likely be fixed in a next update.