From 343872d3e3b225c3d4297d9e3b399f302abe6818 Mon Sep 17 00:00:00 2001 From: Mayank Date: Mon, 20 Apr 2020 19:44:40 +0530 Subject: [PATCH 1/7] replace invoicer with middleware --- configure-box.sh | 2 -- docker-compose.yml | 16 +++++++++++----- invoicer/invoicer.conf | 29 ----------------------------- invoicer/www/.gitkeep | 0 4 files changed, 11 insertions(+), 36 deletions(-) delete mode 100644 invoicer/invoicer.conf delete mode 100644 invoicer/www/.gitkeep diff --git a/configure-box.sh b/configure-box.sh index 44095df..f7d88f8 100755 --- a/configure-box.sh +++ b/configure-box.sh @@ -23,8 +23,6 @@ cd .. echo "Installing RPCAuth into bitcoin.conf" cat secrets/rpcauth.txt >> bitcoin/bitcoin.conf RPCPASS=`cat secrets/rpcpass.txt` -echo "Configuring invoicer rpc info" -sed -i "s/RPCPASS/${RPCPASS}/g; " invoicer/invoicer.conf echo "Configuring LND rpc info" sed -i "s/RPCPASS/${RPCPASS}/g; " lnd/lnd.conf if [ ! -z $TESTNET ]; then diff --git a/docker-compose.yml b/docker-compose.yml index a9bcde1..0179bde 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -40,15 +40,21 @@ services: depends_on: [ bitcoin, web ] network_mode: host stop_grace_period: 1m30s - invoicer: - image: "lncm/invoicer:v0.6.6" + middleware: + image: getumbrel/middleware:v0.0.2 depends_on: [ bitcoin, lnd ] + logging: *default-logging restart: on-failure network_mode: host volumes: - - "${HOME}/invoicer:/root/.lncm" - - "${HOME}/invoicer:/lncm" - - "${HOME}/lnd:/lnd" + - "${HOME}/lnd:/lnd" + environment: + BITCOIN_NETWORK: "mainnet" + BITCOIN_HOST: "0.0.0.0" + RPC_USER: "" + RPC_PASSWORD: "" + LND_NETWORK: "mainnet" + LND_HOST: "127.0.0.1" lnd-unlock: build: ${HOME}/build/lnd-unlock/ depends_on: [ lnd ] diff --git a/invoicer/invoicer.conf b/invoicer/invoicer.conf deleted file mode 100644 index b5fbfae..0000000 --- a/invoicer/invoicer.conf +++ /dev/null @@ -1,29 +0,0 @@ -# Note: all values used in this file are defaults that are used if nothing is provided - -port = 8181 -static-dir = "/lncm/www/" -log-file = "/lncm/invoicer.log" -ln-client = "lnd" - -off-chain-only = false - -[bitcoind] -host = "localhost" -port = 8332 -user = "lncm" -pass = "RPCPASS" - -[lnd] -host = "localhost" -port = 10009 -tls = "/lnd/tls.cert" -kill-count = 4 - -[lnd.macaroon] -invoice = "/lnd/data/chain/bitcoin/mainnet/invoice.macaroon" -readonly = "/lnd/data/chain/bitcoin/mainnet/readonly.macaroon" - - -[users] -# username = "password" - diff --git a/invoicer/www/.gitkeep b/invoicer/www/.gitkeep deleted file mode 100644 index e69de29..0000000 From 4cdbb9f7aab70da33fcdd19a08c2ff1cb6e38e8d Mon Sep 17 00:00:00 2001 From: Mayank Date: Mon, 20 Apr 2020 19:45:46 +0530 Subject: [PATCH 2/7] nginx api config --- nginx/conf.d/default.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nginx/conf.d/default.conf b/nginx/conf.d/default.conf index 85c4971..ec7cbd3 100644 --- a/nginx/conf.d/default.conf +++ b/nginx/conf.d/default.conf @@ -10,8 +10,8 @@ server { try_files $uri $uri/ /index.html; } - location /invoicer/ { + location /api/ { add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; - proxy_pass http://localhost:8181/api/; + proxy_pass http://localhost:3005/; } } From 5965adc3e41d510d9aa28240025e903bf89d7e8f Mon Sep 17 00:00:00 2001 From: Mayank Chhabra Date: Mon, 27 Apr 2020 00:45:44 +0530 Subject: [PATCH 3/7] v0.0.4 middleware --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index 0179bde..aecb1cc 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -41,7 +41,7 @@ services: network_mode: host stop_grace_period: 1m30s middleware: - image: getumbrel/middleware:v0.0.2 + image: getumbrel/middleware:v0.0.4 depends_on: [ bitcoin, lnd ] logging: *default-logging restart: on-failure From 89301f811c9c15fb31b7c830e2f9aa948e04b2e6 Mon Sep 17 00:00:00 2001 From: BT Date: Tue, 28 Apr 2020 17:10:47 +0700 Subject: [PATCH 4/7] Fix up the pathname --- install-box.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install-box.sh b/install-box.sh index 2b49ed6..62aa029 100644 --- a/install-box.sh +++ b/install-box.sh @@ -13,7 +13,7 @@ echo "Cloning to current working directory from github..." git init -git remote add origin https://github.com/lncm/thebox-compose-system.git +git remote add origin https://github.com/getumbrel/umbrel-compose.git git fetch git reset origin/master git checkout -t origin/master From 65e3ca514b5e64c8e07d0e8a3c97af966c460db8 Mon Sep 17 00:00:00 2001 From: BT Date: Tue, 28 Apr 2020 22:04:05 +0700 Subject: [PATCH 5/7] Umbrelize the configuration --- lnd/lnd.conf | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lnd/lnd.conf b/lnd/lnd.conf index a2773d4..b31f1c7 100644 --- a/lnd/lnd.conf +++ b/lnd/lnd.conf @@ -5,7 +5,9 @@ rpclisten=0.0.0.0:10009 restlisten=0.0.0.0:8080 maxpendingchannels=3 minchansize=10000 -alias=LNCM Default Box +; This should be re-written via script +alias=My Umbrel Node +; This should also be re-written by script color=#ffe200 ; 0.9.X keysend functionality accept-keysend=true @@ -30,7 +32,7 @@ bitcoind.zmqpubrawtx=tcp://127.0.0.1:28333 bitcoin.active=1 bitcoin.mainnet=1 ; Use neutrino for now, but maybe it could be permanent and then switch -; to a full node once its working? +; to a full node if theres enough space bitcoin.node=neutrino bitcoin.defaultchanconfs=2 From 4af938e5ef4f552053d1633777de27b5759d0445 Mon Sep 17 00:00:00 2001 From: BT Date: Tue, 28 Apr 2020 22:05:35 +0700 Subject: [PATCH 6/7] Umbrel colors --- lnd/lnd.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lnd/lnd.conf b/lnd/lnd.conf index b31f1c7..5ca8775 100644 --- a/lnd/lnd.conf +++ b/lnd/lnd.conf @@ -8,7 +8,7 @@ minchansize=10000 ; This should be re-written via script alias=My Umbrel Node ; This should also be re-written by script -color=#ffe200 +color=#5351FB ; 0.9.X keysend functionality accept-keysend=true From 7be1a20e0e569c0b2cd25d9310da8bc9e021d6ff Mon Sep 17 00:00:00 2001 From: Mayank Date: Wed, 6 May 2020 16:23:28 +0530 Subject: [PATCH 7/7] v0.0.5 middleware --- docker-compose.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index aecb1cc..7f58666 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -41,7 +41,7 @@ services: network_mode: host stop_grace_period: 1m30s middleware: - image: getumbrel/middleware:v0.0.4 + image: getumbrel/middleware:v0.0.5 depends_on: [ bitcoin, lnd ] logging: *default-logging restart: on-failure @@ -49,8 +49,8 @@ services: volumes: - "${HOME}/lnd:/lnd" environment: - BITCOIN_NETWORK: "mainnet" BITCOIN_HOST: "0.0.0.0" + RPC_PORT: "8332" RPC_USER: "" RPC_PASSWORD: "" LND_NETWORK: "mainnet"