From 3f6393a943017234f6bb84a1d1d09a04dc707abd Mon Sep 17 00:00:00 2001 From: Tiago vasconcelos Date: Mon, 5 Jul 2021 10:02:36 +0100 Subject: [PATCH 01/13] Small fix to disable all extensions --- .env.example | 1 + lnbits/helpers.py | 3 +++ 2 files changed, 4 insertions(+) diff --git a/.env.example b/.env.example index 6ca9a281..1994ab1d 100644 --- a/.env.example +++ b/.env.example @@ -17,6 +17,7 @@ LNBITS_DEFAULT_WALLET_NAME="LNbits wallet" LNBITS_DATA_FOLDER="./data" # LNBITS_DATABASE_URL="postgres://user:password@host:port/databasename" +# disable selected extensions, or use "all" to disable all extensions LNBITS_DISABLED_EXTENSIONS="amilk,ngrok" LNBITS_FORCE_HTTPS=true LNBITS_SERVICE_FEE="0.0" diff --git a/lnbits/helpers.py b/lnbits/helpers.py index 0370edbc..8b57fe2b 100644 --- a/lnbits/helpers.py +++ b/lnbits/helpers.py @@ -29,6 +29,9 @@ class ExtensionManager: def extensions(self) -> List[Extension]: output = [] + if "all" in self._disabled: + return output + for extension in [ ext for ext in self._extension_folders if ext not in self._disabled ]: From a9163a14562c31182073d830a024b484ae4d3083 Mon Sep 17 00:00:00 2001 From: Ben Arc Date: Wed, 7 Jul 2021 10:53:53 +0100 Subject: [PATCH 02/13] Added umbrel/tor guide --- docs/guide/installation.md | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/docs/guide/installation.md b/docs/guide/installation.md index 9fb8a3e3..023d359d 100644 --- a/docs/guide/installation.md +++ b/docs/guide/installation.md @@ -4,9 +4,7 @@ title: Basic installation nav_order: 2 --- - -Basic installation -================== +# Basic installation Download this repo and install the dependencies: @@ -31,10 +29,16 @@ Then you can restart it and it will be using the new settings. You might also need to install additional packages or perform additional setup steps, depending on the chosen backend. See [the short guide](./wallets.md) on each different funding source. -Docker installation -=================== +# Additional guides + +### LNbits running on Umbrel behind Tor + +If you want to run LNbits on your Umbrel but want it to be reached through clearnet, _Uxellodunum_ made an extensive [guide](https://community.getumbrel.com/t/guide-lnbits-without-tor/604) on how to do it. + +### Docker installation To install using docker you first need to build the docker image as: + ``` git clone https://github.com/lnbits/lnbits.git cd lnbits/ # ${PWD} referred as @@ -42,19 +46,24 @@ docker build -t lnbits . ``` You can launch the docker in a different directory, but make sure to copy `.env.example` from lnbits there + ``` cp /.env.example .env ``` + and change the configuration in `.env` as required. Then create the data directory for the user ID 1000, which is the user that runs the lnbits within the docker container. + ``` mkdir data sudo chown 1000:1000 ./data/ ``` Then the image can be run as: + ``` docker run --detach --publish 5000:5000 --name lnbits --volume ${PWD}/.env:/app/.env --volume ${PWD}/data/:/app/data lnbits ``` + Finally you can access your lnbits on your machine at port 5000. From ad64972ddf9a1431cb2fd35b964b88e6b7fe52f8 Mon Sep 17 00:00:00 2001 From: Arc <33088785+arcbtc@users.noreply.github.com> Date: Wed, 7 Jul 2021 10:57:45 +0100 Subject: [PATCH 03/13] Update installation.md --- docs/guide/installation.md | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/docs/guide/installation.md b/docs/guide/installation.md index 023d359d..4af5d393 100644 --- a/docs/guide/installation.md +++ b/docs/guide/installation.md @@ -4,7 +4,9 @@ title: Basic installation nav_order: 2 --- -# Basic installation + +Basic installation +================== Download this repo and install the dependencies: @@ -29,16 +31,10 @@ Then you can restart it and it will be using the new settings. You might also need to install additional packages or perform additional setup steps, depending on the chosen backend. See [the short guide](./wallets.md) on each different funding source. -# Additional guides - -### LNbits running on Umbrel behind Tor - -If you want to run LNbits on your Umbrel but want it to be reached through clearnet, _Uxellodunum_ made an extensive [guide](https://community.getumbrel.com/t/guide-lnbits-without-tor/604) on how to do it. - -### Docker installation +Docker installation +=================== To install using docker you first need to build the docker image as: - ``` git clone https://github.com/lnbits/lnbits.git cd lnbits/ # ${PWD} referred as @@ -46,24 +42,27 @@ docker build -t lnbits . ``` You can launch the docker in a different directory, but make sure to copy `.env.example` from lnbits there - ``` cp /.env.example .env ``` - and change the configuration in `.env` as required. Then create the data directory for the user ID 1000, which is the user that runs the lnbits within the docker container. - ``` mkdir data sudo chown 1000:1000 ./data/ ``` Then the image can be run as: - ``` docker run --detach --publish 5000:5000 --name lnbits --volume ${PWD}/.env:/app/.env --volume ${PWD}/data/:/app/data lnbits ``` - Finally you can access your lnbits on your machine at port 5000. + +Additional guides +=================== + +## LNbits running on Umbrel behind Tor + +If you want to run LNbits on your Umbrel but want it to be reached through clearnet, _Uxellodunum_ made an extensive [guide](https://community.getumbrel.com/t/guide-lnbits-without-tor/604) on how to do it. + From b02952d99dbae5e216255994d767f6b2325f7294 Mon Sep 17 00:00:00 2001 From: Ben Arc Date: Wed, 7 Jul 2021 10:58:21 +0100 Subject: [PATCH 04/13] Added umbrel/tor guide --- docs/guide/installation.md | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/docs/guide/installation.md b/docs/guide/installation.md index 4af5d393..8a2782b7 100644 --- a/docs/guide/installation.md +++ b/docs/guide/installation.md @@ -4,9 +4,7 @@ title: Basic installation nav_order: 2 --- - -Basic installation -================== +# Basic installation Download this repo and install the dependencies: @@ -31,10 +29,16 @@ Then you can restart it and it will be using the new settings. You might also need to install additional packages or perform additional setup steps, depending on the chosen backend. See [the short guide](./wallets.md) on each different funding source. -Docker installation -=================== +# Additional guides + +### LNbits running on Umbrel behind Tor + +If you want to run LNbits on your Umbrel but want it to be reached through clearnet, _Uxellodunum_ made an extensive [guide](https://community.getumbrel.com/t/guide-lnbits-without-tor/604) on how to do it. + +### Docker installation To install using docker you first need to build the docker image as: + ``` git clone https://github.com/lnbits/lnbits.git cd lnbits/ # ${PWD} referred as @@ -42,27 +46,30 @@ docker build -t lnbits . ``` You can launch the docker in a different directory, but make sure to copy `.env.example` from lnbits there + ``` cp /.env.example .env ``` + and change the configuration in `.env` as required. Then create the data directory for the user ID 1000, which is the user that runs the lnbits within the docker container. + ``` mkdir data sudo chown 1000:1000 ./data/ ``` Then the image can be run as: + ``` docker run --detach --publish 5000:5000 --name lnbits --volume ${PWD}/.env:/app/.env --volume ${PWD}/data/:/app/data lnbits ``` + Finally you can access your lnbits on your machine at port 5000. -Additional guides -=================== +# Additional guides ## LNbits running on Umbrel behind Tor If you want to run LNbits on your Umbrel but want it to be reached through clearnet, _Uxellodunum_ made an extensive [guide](https://community.getumbrel.com/t/guide-lnbits-without-tor/604) on how to do it. - From ca29c3f2389b2a7dd1e7c994fa13cff0640117f7 Mon Sep 17 00:00:00 2001 From: Arc <33088785+arcbtc@users.noreply.github.com> Date: Wed, 7 Jul 2021 11:06:11 +0100 Subject: [PATCH 05/13] Update .env.example --- .env.example | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 1994ab1d..22e7d052 100644 --- a/.env.example +++ b/.env.example @@ -51,12 +51,12 @@ LNBITS_KEY=LNBITS_ADMIN_KEY LND_GRPC_ENDPOINT=127.0.0.1 LND_GRPC_PORT=11009 LND_GRPC_CERT="/home/bob/.config/Zap/lnd/bitcoin/mainnet/wallet-1/data/chain/bitcoin/mainnet/tls.cert" -LND_GRPC_MACAROON="/home/bob/.config/Zap/lnd/bitcoin/mainnet/wallet-1/data/chain/bitcoin/mainnet/admin.macaroon" +LND_GRPC_MACAROON="/home/bob/.config/Zap/lnd/bitcoin/mainnet/wallet-1/data/chain/bitcoin/mainnet/admin.macaroon or HEXSTRING" # LndRestWallet LND_REST_ENDPOINT=https://127.0.0.1:8080/ LND_REST_CERT="/home/bob/.config/Zap/lnd/bitcoin/mainnet/wallet-1/data/chain/bitcoin/mainnet/tls.cert" -LND_REST_MACAROON="HEXSTRING" +LND_REST_MACAROON="/home/bob/.config/Zap/lnd/bitcoin/mainnet/wallet-1/data/chain/bitcoin/mainnet/admin.macaroon or HEXSTRING" # LNPayWallet LNPAY_API_ENDPOINT=https://api.lnpay.co/v1/ From bba3cbc3e4af6b5bd969c8dd48d9775700fa609d Mon Sep 17 00:00:00 2001 From: Ben Arc Date: Wed, 7 Jul 2021 23:33:55 +0100 Subject: [PATCH 06/13] Ngrok benched Too many people complaining about it downloading ngrok, so its now been disabled via its config --- lnbits/extensions/ngrok/{config.json => config.json.example} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename lnbits/extensions/ngrok/{config.json => config.json.example} (100%) diff --git a/lnbits/extensions/ngrok/config.json b/lnbits/extensions/ngrok/config.json.example similarity index 100% rename from lnbits/extensions/ngrok/config.json rename to lnbits/extensions/ngrok/config.json.example From 6ba8aa65e03f5e8d6f822fcce760cd14eb842e5e Mon Sep 17 00:00:00 2001 From: Arc <33088785+arcbtc@users.noreply.github.com> Date: Sat, 10 Jul 2021 17:57:05 +0100 Subject: [PATCH 07/13] Added telegram link --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index bc700bfd..c5c1257c 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,7 @@ LNbits # LNbits v0.3 BETA, free and open-source lightning-network wallet/accounts system +(Join us on [https://t.me/lnbits](https://t.me/lnbits)) Use [lnbits.com](https://lnbits.com), or run your own LNbits server! LNbits is a very simple Python server that sits on top of any funding source, and can be used as: From 6350a74ab9c91bea7988567384238835cfe9473c Mon Sep 17 00:00:00 2001 From: Arc <33088785+arcbtc@users.noreply.github.com> Date: Sat, 10 Jul 2021 17:59:14 +0100 Subject: [PATCH 08/13] Added telegram link --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index c5c1257c..cbcf3797 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,7 @@ LNbits # LNbits v0.3 BETA, free and open-source lightning-network wallet/accounts system (Join us on [https://t.me/lnbits](https://t.me/lnbits)) + Use [lnbits.com](https://lnbits.com), or run your own LNbits server! LNbits is a very simple Python server that sits on top of any funding source, and can be used as: From 3331dfeab6395e2ed72d4e406d8e979b911f4521 Mon Sep 17 00:00:00 2001 From: davidfrayne Date: Mon, 12 Jul 2021 13:58:10 +0100 Subject: [PATCH 09/13] Fix payments filter on wallets.html --- lnbits/core/templates/core/wallet.html | 1 + 1 file changed, 1 insertion(+) diff --git a/lnbits/core/templates/core/wallet.html b/lnbits/core/templates/core/wallet.html index 31eba13d..d48e36b8 100644 --- a/lnbits/core/templates/core/wallet.html +++ b/lnbits/core/templates/core/wallet.html @@ -92,6 +92,7 @@ :columns="paymentsTable.columns" :pagination.sync="paymentsTable.pagination" no-data-label="No transactions made yet" + :filter="paymentsTable.filter" > {% raw %}